Last active
March 2, 2018 08:47
-
-
Save sheharyarn/05ea8431a73065de6ccd161e43461d66 to your computer and use it in GitHub Desktop.
Quickly work with BTC Testnet
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
testnet=1 | |
server=1 | |
# enable SSL for RPC server | |
#rpcssl=1 | |
rpcallowip=0.0.0.0/0 | |
rpcuser=admin | |
rpcpassword=123 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function btc { | |
local server="bitcoind -testnet" | |
local client="bitcoin-cli -testnet" | |
local dir="$HOME/.bitcoin/testnet3" | |
if [ $# -eq 0 ] ; then | |
$client --help | |
else | |
case $1 in | |
start) $server -server -daemon ;; | |
stop) $client stop ;; | |
tail) tail -f $dir/debug.log ;; | |
info) $client getinfo ;; | |
blockchain) $client getblockchaininfo ;; | |
network) $client getnetworkinfo ;; | |
*) $client $@ ;; | |
esac | |
fi | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment