1
0
mirror of https://github.com/romanz/electrs.git synced 2024-11-19 09:54:09 +01:00

Add helper scripts

This commit is contained in:
Roman Zeyde 2020-10-25 14:23:56 +02:00
parent 82c50feea2
commit eb413a0117
No known key found for this signature in database
GPG Key ID: 87CAE5FA46917CBB
2 changed files with 31 additions and 0 deletions

15
query.sh Executable file
View File

@ -0,0 +1,15 @@
#!/bin/bash
set -eux
cd `dirname $0`
cargo fmt
cargo build --all --release
NETWORK=$1
shift
QUERY="target/release/electrs_query --network $NETWORK --db-dir ./db --daemon-dir $HOME/.bitcoin"
export RUST_LOG=${RUST_LOG-info}
$QUERY $*
# use SIGINT to quit

16
server.sh Executable file
View File

@ -0,0 +1,16 @@
#!/bin/bash
set -eux
cd `dirname $0`
cargo fmt
cargo build --all --release
NETWORK=$1
shift
DB=./db # $HOME/tmp/electrs_db/mainnet_zstd
QUERY="target/release/electrs_rpc --network $NETWORK --db-dir $DB --daemon-dir $HOME/.bitcoin"
export RUST_LOG=${RUST_LOG-info}
$QUERY $*
# use SIGINT to quit