From: thunderbiscuit Date: Wed, 9 Jun 2021 20:02:55 +0000 (-0400) Subject: Add install instructions for crates.io X-Git-Tag: v0.3.0~39 X-Git-Url: http://internal-gitweb-vhost/script/%22https:/struct.MemoryDatabase.html?a=commitdiff_plain;h=7aeb6bb88257986c90f2dee5862a3cdb6659dcac;p=bdk-cli Add install instructions for crates.io --- diff --git a/README.md b/README.md index 75e71b9..bacb488 100644 --- a/README.md +++ b/README.md @@ -8,6 +8,28 @@ This project provides a command line interface (cli) Bitcoin wallet library and [`REPL`](https://en.wikipedia.org/wiki/Read%E2%80%93eval%E2%80%93print_loop) wallet tool based on the [bdk](https://github.com/bitcoindevkit/bdk) library. +## Install bdk-cli +### From source +To install dev version of `bdk-cli` from local git repo: + +```shell +cd +cargo install --path . +bdk-cli help # to verify it worked +``` + +By default an electrum backend is used, to use esplora instead the relative feature must be enabled and the esplora address must be specified. Note we are enabling logs to see the calls to esplora. + +```shell +RUST_LOG=debug cargo run --features esplora -- wallet -e https://blockstream.info/api/ --descriptor "wpkh(tpubEBr4i6yk5nf5DAaJpsi9N2pPYBeJ7fZ5Z9rmN4977iYLCGco1VyjB9tvvuvYtfZzjD5A8igzgw3HeWeeKFmanHYqksqZXYXGsw5zjnj7KM9/*)" sync +``` + +### From crates.io +You can the install the binaries for the latest tag of `bdk-cli` directly from [crates.io](https://crates.io/crates/bdk-cli) like so: +```sh +cargo install bdk-cli --features repl,electrum,esplora +``` + ### bdk-cli bin usage examples To get usage information for the `bdk-cli` bin use the below command which returns a list of @@ -43,18 +65,3 @@ To generate a new extended master key, suitable for using in a descriptor: ```shell cargo run -- key generate ``` - -To install dev version of `bdk-cli` from local git repo: - -```shell -cd -cargo install --path . - -bdk-cli help # to verify it worked -``` - -By default an electrum backend is used, to use esplora instead the relative feature must be enabled and the esplora address must be specified. Note we are enabling logs to see the calls to esplora. - -```shell -RUST_LOG=debug cargo run --features esplora -- wallet -e https://blockstream.info/api/ --descriptor "wpkh(tpubEBr4i6yk5nf5DAaJpsi9N2pPYBeJ7fZ5Z9rmN4977iYLCGco1VyjB9tvvuvYtfZzjD5A8igzgw3HeWeeKFmanHYqksqZXYXGsw5zjnj7KM9/*)" sync -```