Skip to content
Snippets Groups Projects
Commit 015f88a3 authored by Robert Martin-Legene's avatar Robert Martin-Legene
Browse files

sendether.sh now uses geth_attach from libbfa.sh

parent 9a5370da
No related branches found
No related tags found
No related merge requests found
......@@ -3,14 +3,16 @@
if [ -z "${BFAHOME}" ]; then echo "\$BFAHOME not set. Did you source bfa/bin/env ?" >&2; exit 1; fi
source ${BFAHOME}/bin/libbfa.sh || exit 1
test -n "$1" ||
fatal "Send to whom?"
test -n "$2" ||
fatal "Send how much?"
function usage
{
fatal "Usage: $0 <dest-addr> <amount-of-ether>"
}
test $# -eq 2 || usage
rcpt=$1
eth=$2
cat<<EOJS | geth --datadir node1 attach
cat<<EOJS | geth_attach
eth.sendTransaction({from:eth.accounts[0], to: "${rcpt}", value: web3.toWei(${eth}, "ether")})
EOJS
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment