Skip to content

Commit

Permalink
gettransaction command ready
Browse files Browse the repository at this point in the history
  • Loading branch information
PsySc0rpi0n committed Oct 12, 2019
1 parent a522f75 commit bc850a8
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions TugaRevoBTC.sh
Original file line number Diff line number Diff line change
Expand Up @@ -206,19 +206,17 @@ check_txid(){
local strlen
echo "Enter transaction ID:"
read -p '> ' txid
echo "\$TxID is: $txid"
strlen=$($(echo -n "txid" | wc -c))
echo "strlen is $strlen"
strlen=${#txid}
while [[ -z $txid || $strlen -ne $txidlen ]]
do
echo "TxID not valid. Please enter a valid one: "
read -p '> ' txid
strlen=$(echo -n "txid" | wc -c)
strlen=${#txid}
done
if [[ $used_net == "testnet" ]]; then
bitcoin-cli -testnet gettransaction $txid
else
bitcoin-cli gettransaction $txid
bitcoin-cli gettransaction "$txid"
fi
}

Expand Down

0 comments on commit bc850a8

Please sign in to comment.