Uncoment and add input tx survey
This commit is contained in:
parent
1fe76a70a3
commit
8547a1cef8
|
@ -141,15 +141,11 @@ do
|
||||||
if [[ $g1_author != $g1pub ]]; then
|
if [[ $g1_author != $g1pub ]]; then
|
||||||
sleep 3
|
sleep 3
|
||||||
#printf '%s\n' "silkaj -af --file ~/.ssb/secret.dunikey tx --output $g1_author --amountUD 0.1 --comment _SSB:LIKE:$target_id"
|
#printf '%s\n' "silkaj -af --file ~/.ssb/secret.dunikey tx --output $g1_author --amountUD 0.1 --comment _SSB:LIKE:$target_id"
|
||||||
|
#### SEND 10 LOVE = 0.1 DU to $g1_author wallet
|
||||||
# silkaj -p "$duniter_server" -af --file ~/.ssb/secret.dunikey tx --output $g1_author --amountUD 0.1 --comment "_SSB:LIKE:$target_id" -y 2>/dev/null
|
silkaj -p "$duniter_server" -af --file ~/.ssb/secret.dunikey tx --output $g1_author --amountUD 0.1 --comment "_SSB:LIKE:$target_id" -y 2>/dev/null
|
||||||
|
#### WRITE RESPONSE MESSAGE
|
||||||
|
|
||||||
#thank_you_msg="Hi there! I liked your post and thus sent you Ğ1 #libremoney. We don\'t really know how you may be able to use it but, hey, that is still money, right? Cheers!"
|
|
||||||
|
|
||||||
sbotc publish '{"type":"post","text":"Thanks for this post ; I have just sent you G1 #libremoney. Claim it! ", "branch": "'"$target_id"'", "root": "'"$root_id"'"}'
|
sbotc publish '{"type":"post","text":"Thanks for this post ; I have just sent you G1 #libremoney. Claim it! ", "branch": "'"$target_id"'", "root": "'"$root_id"'"}'
|
||||||
|
sleep 60 # DO NOT OVER CHARGE DUNITER
|
||||||
#sleep 60 # DO NOT OVER CHARGE DUNITER
|
|
||||||
else
|
else
|
||||||
echo "I LIKE MY MESSAGE $target_id"
|
echo "I LIKE MY MESSAGE $target_id"
|
||||||
fi
|
fi
|
||||||
|
@ -160,3 +156,20 @@ do
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
|
#######################################################################
|
||||||
|
## SCAN G1 BLOCKCHAIN FOR INCOMING TX
|
||||||
|
#######################################################################
|
||||||
|
EVERY=1
|
||||||
|
TIMEBEFORE=$(date --date="-$EVERY minutes" +"%s")
|
||||||
|
TIMESTAMP=$(date +"%s")
|
||||||
|
#log "GETTING last $EVERY mn TX : https://duniter-g1.p2p.legal/tx/history/$g1pub/times/$TIMEBEFORE/$TIMESTAMP"
|
||||||
|
curl -s https://$duniter_server/tx/history/$g1pub/times/$TIMEBEFORE/$TIMESTAMP | jq '.history.pending' | jq '.[].comment' > /tmp/zenfontain.g1tx.txt
|
||||||
|
while read txincmd
|
||||||
|
do
|
||||||
|
export $txincmd
|
||||||
|
log "$g1pub TX IN PENDING !! COMMENT = " $txincmd
|
||||||
|
sbotc publish '{"type":"post","text":"I am receiving G1 on my SSB Wallet $g1pub"}'
|
||||||
|
|
||||||
|
|
||||||
|
done < /tmp/zenfontain.g1tx.txt
|
||||||
|
|
Loading…
Reference in New Issue