Adding hardware signers, so that hardware wallets can be used to sign transactions.
### Notes to the reviewers
~~It doesn't work 100% yet for me.
I am using the following wallet:
https://github.com/RCasatta/electrum2descriptors/blob/main/tests/wallets2descriptors.rs#L89
https://github.com/RCasatta/electrum2descriptors/blob/main/tests/wallets/multisig_hw_segwit
I can create and sign a transaction with this version of bdk-cli. It displays the details on the Trezor and everything looks good so far. But in the CLI output of bdk-cli it says "is_finalized= false" and when I open the supposedly signed tx in Electrum, it aslo says "Status: Unsigned".
So, something must still be missing.~~
Initially I had some dependency problems, so I deleted Cargo.lock. That solved the dependency problems, but that's the reason for the large diff on that file.
## Changelog notice
Added hardware signers through the use of HWI
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [ ] I've added tests for the new feature
* [ ] I've added docs for the new feature
* [x] I've updated `CHANGELOG.md`
Update `bdk` from 0.27 to 0.27.1 to fix bitcoindevkit/bdk#866.
### Notes to the reviewers
Once we get this verified for `bdk-cli` and `bdk-ffi` I'll publish the new bdk release and update this PR to use the new version.
## Changelog notice
Changed
- Update bdk from 0.27 to 0.27.1 to fix bitcoindevkit/bdk#866.
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
Upgrades to bdk `v0.27.0-rc.1`. Pins dependency `zip` to `v0.6`, as latest version of `zip` moved up their MSRV to `1.59`.
### Notes to the reviewers
of the PR were done in a specific way -->
## Changelog notice
<!-- Notice the release manager should include in the release tag message changelog -->
<!-- See https://keepachangelog.com/en/1.0.0/ for examples -->
- BDK version bumped to `0.27`.
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
As BDK bumped its stable to 1.65, it is safe for us to move it up also.
### Notes to the reviewers
`1.65` cause clippy warning that `Eq` isn't derived while `PartialEq` is derived for the commands. We can't derive `Eq` for commands, as there is a `fee_rate` which is `f32` which isn't `Eq`, and this effect cascades to all structures. We also need `PartialEq` for the tests.
A few options were:
- allow the clippy warning conditionally for `1.65`, `1.57` doesn't have that lint. The way to do that is by creating custom features for different versions and making a build script that activates specific features for specific versions. Feature gate the clippy lint. or use https://github.com/dtolnay/rustversion which is an extra dep.
- Remove `PartialEq` and create a method on `CliOpts` to translate it into `Vec<String>`, and then perform the tests.
- Make `fee_rate` `u32` and derive `Eq` for all.
I went for the last option as it seemed less complex, and not too bad(?). For bdk_cli as majorly a testing tool, it might not need floating point granularity and users can still test out with `u32` fee_rates. Internally it converts it back to `f32`.
Suggestions welcome.
## Changelog notice
- Bumped rustc `stable` to 1.65.
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
As we are already at msrv 1.57.0, so we can bump electrsd to v0.22.
Which fixes #85 and potentially #131 too..
### Notes to the reviewers
## Changelog notice
Bump `electrsd` version to `v0.22.*`.
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
Follow the bdk main release process, expect making intermediate release candidate.
Add other issue templates.
Add Development_cycle notes.
Update PR template to include changelog section.
Update changelog to include instruction of new change log format.
### Notes to the reviewers
Please re-check the `minor_release.md` file where I updated the release process without `rc` creation.
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
rajarshimaitra [Wed, 11 Jan 2023 17:01:42 +0000 (22:31 +0530)]
Update the release cycle
Follow the bdk main release process, expect making intermediate release
candidate.
Add other issue templates.
Add Development_cycle notes.
Update PR template to include changelog section.
Update changelog to include instruction of new changelog format.
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
Upgrade to bdk v0.26.0
### Notes to the reviewers
<!-- In this section you can include notes directed to the reviewers, like explaining why some parts
of the PR were done in a specific way -->
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
Fixes #97
Add a finalizer check before broadcasting psbts.
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
Remove mention of compact_filters from README until it can be re-enabled
### Notes to the reviewers
I didn't notice this before I merged #125.
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
Fixes #112
Removes compact block filters temporarily.
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
Fixes #113.
This is an attempt to migrate from `structopt` to `clap v0.3` which provides very similar kind of derives as `structopt`. Changes are straight forward. But this comes with few more problems.
- with clap `v3.2.22` the MSRV pushes up to `1.57.0`.. The last clap of MSRV `1.56.0` was `clap 3.2.5`.. But even that doesn't seem to be working at MSRV `1.56.0` anymore, as bunch of underlying lib has upgraded.
- `clap v3.0` doesn't seem to support custom vector parsing well, reported here https://github.com/clap-rs/clap/issues/1704. This is required for `recipient` parsing which is a `Vec<(Script, u32)>`. Workaround for that is to use vecs of strings and parse them at runtime in `create_tx` handler. Included in the PR.
### Notes to the reviewers
`structopt` is currently freezed at `clap 2.0` and doesn't seem to intend on updating and currently its has unmaintained vulnerability. And `clap v3.0` onward seems to replacing everything that `structopt` did before. So this means we should also look for ways to migrate from `strcutopt` to `clap`.. But `clap` seemed to have moved ahead than our MSRV `1.56.0`.. So we need to take up a call on that.. Opened this PR to facilitate that discussion..
This is draft until we figure what to do..
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
rajarshimaitra [Sun, 2 Oct 2022 13:52:45 +0000 (19:22 +0530)]
Move from structopt to clap
This commit include changes to move from structopt to clap.
This includes:
- Update Cargo.toml.
- Update commands from structopt to clap.
- Some auxiliary fixes in commands.
- Updates main.
I also had to add `base64` as a new dependency because it's not exported by `bdk`.
There's probably a more elegant way to fix the `wasm.rs` compiler function for descriptor.translate_pk, and I don't
know how create a unit test it since it only runs on wasm32. But at least it builds so I think that's close enough for now.
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
Candidate PR for bdk version update..
### Notes to the reviewers
<!-- In this section you can include notes directed to the reviewers, like explaining why some parts
of the PR were done in a specific way -->
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
This PR adds a module to bdk-cli that exposes some structures/functions to WASM. You can see it in use here: https://github.com/bitcoindevkit/bitcoindevkit.org/pull/118
### Notes to the reviewers
Based on #116
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [ ] I've added tests for the new feature
* [ ] I've added docs for the new feature
* [x] I've updated `CHANGELOG.md`
#### Bugfixes:
* [ ] This pull request breaks the existing API
* [ ] I've added tests to reproduce the issue which are now passing
* [ ] I'm linking the issue being fixed by this PR
Making sure to create the wallet dir only when necessary (database is either sqlite or key-value)
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [ ] I've added tests for the new feature
* [ ] I've added docs for the new feature
* [ ] I've updated `CHANGELOG.md`
#### Bugfixes:
* [ ] This pull request breaks the existing API
* [ ] I've added tests to reproduce the issue which are now passing
* [ ] I'm linking the issue being fixed by this PR
Add a module "wasm" with utilities to be used in the bdk playground:
- A WasmWallet structure, to create a wallet and run commands
- A compile function, to compile policies into descriptors
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
This enables users to send an arbitrary string message through a txn-output. The maximum size of this string-literal can be length of 80-bytes.
<!-- Describe the purpose of this PR, what's being adding and/or fixed -->
### Notes to the reviewers
<!-- In this section you can include notes directed to the reviewers, like explaining why some parts
of the PR were done in a specific way -->
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [x] I've added tests for the new feature
* [x] I've added docs for the new feature
* [x] I've updated `CHANGELOG.md`
#### Bugfixes:
* [ ] This pull request breaks the existing API
* [ ] I've added tests to reproduce the issue which are now passing
* [ ] I'm linking the issue being fixed by this PR
Daniela Brozzoni [Tue, 30 Aug 2022 15:22:12 +0000 (17:22 +0200)]
`open_database` avoids creating a wallet dir if...
...not necessary
This is useful for the wasm integration, where we want to call the
`open_database` function directly, without wanting it to create any
directories.
Note that when using bdk-cli normally, it won't create a db directory
if it's useless, but it will still create a base directory (even if
empty). This is suboptimal, but fixing it would require a quite big
refactor to the code.
After #99 the previous documentation have been removed and new docs as per `structopts` documentation. This PR adds more documentation across the crate..
This PR is above #102 , to accommodate all the further refactoring changes.
The Readme About section have been updated with more details.. Readme format made aligned with the BDK project itself..
The Readme file is used itself as the crate level documentation in docs.rs too..
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
On the name :
If Bitcoin wallet devs had to have a "calculator", this is what it might look like. One single interface to do all wallet and node operations.
This PR does the following
- Update electrsd to latest version. We need this to use it for out auto deployed backends.
- Add the remaining codes to `nodes.rs` module to define basic node operation apis on the `Nodes` enum.
- Add a new `node` command in ` CliSubCommand` which has its own subcommand `NodeSubCommand`, These subcommands are essentially `bitcoin-cli` calls. And only the basic ones are included so far. We can also compose multiple `bitcoin-cli` calls to create our own commands in future.
- Update the `handlers` to handle newly added `NodeSubCommands`.
- Update in `utils` :
- This includes handling auto blockchain client creation for `regtest-*` features.
- update on the directory creation workflow. We are creating many directories for many stuffs, and I was trying to figure out the easiest way to keep the whole datadir struct intact, no matter where the user points its `datadir` to. Note that now `datadir` is a global app option, not just available for `regtest` nodes. Default `datadir` is the previous `~/.bdk-bitcoin`.
- Finally add an integration test in `tests/integration.rs` that runs a basic wallet operation with a bdk-cli wallet connected to auto deployed regtest-bitcoin/electrum.
### Notes to the reviewers
@sandipndev @krtk6160. I feel this PR is now ready to try out #87 .
Also looking for more integration test ideas too add into.
basic `node` usage looks like this
```
$ ./target/debug/bdk-cli node --help
bdk-cli-node 0.5.0
Regtest Node mode
USAGE:
bdk-cli node <SUBCOMMAND>
FLAGS:
-h, --help
Prints help information
-V, --version
Prints version information
SUBCOMMANDS:
generate Generate blocks
getbalance Get Wallet balance
getinfo Get info
getnewaddress Get new address from node's test wallet
help Prints this message or the help of the given subcommand(s)
sendtoaddress Send to an external wallet address
```
The biggest benefit is I think in the `repl` mode. That now kinda becomes an integrated tool the like python interpreter to operate a bdk-cli and a bitcoin backend from one single interface.
I am excited to see what kind of demonstrations with bdk-cli we can create with this..
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [x] I've added tests for the new feature
* [x] I've added docs for the new feature
* [x] I've updated `CHANGELOG.md`
- Update the handlers to handle node commands
- Main `handle_command()` function signature changed to only take
in a `CliOpts`. This is helpful for wasm or any other binding
produced on bdk-cli.
- Update `bdk` and `bdk-reserves` to v0.22.0.
- Change rpc `--skip-blocks` option to `--start-time` which specifies time initial sync will start scanning from.
### Notes to the reviewers
I haven't verified the bits and bytes of the new `reserves` PSBT in the tests. I assume it's different for the same reason as the other tests in `bdk-reserves` when we switched to bdk 0.22, but I could use some help confirming that.
**This is draft until `bdk` and `bdk-reservers` v0.22 are published.**
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
We previously had the esplora-reqwest feature, but it would use
sync reqwest, as the "async-interface" feature in BDK wasn't set.
This commit sets this feature so that using `esplora-reqwest` always
uses async mode.
### Notes to the reviewers
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [x] I've added tests for the new feature
* [ ] I've added docs for the new feature
* [x] I've updated `CHANGELOG.md`
Daniela Brozzoni [Wed, 24 Aug 2022 22:06:53 +0000 (23:06 +0100)]
Use async with esplora-reqwest
We previously had the esplora-reqwest feature, but it would use
sync reqwest, as the "async-interface" feature in BDK wasn't set.
This commit sets this feature so that using `esplora-reqwest` always
uses async mode.
This commit also adds the testing for memory database and key value
database in CI
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
<!-- Describe the purpose of this PR, what's being adding and/or fixed -->
### Notes to the reviewers
<!-- In this section you can include notes directed to the reviewers, like explaining why some parts
of the PR were done in a specific way -->
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### Bugfixes:
* [ ] This pull request breaks the existing API
* [x] I've added tests to reproduce the issue which are now passing
* [ ] I'm linking the issue being fixed by this PR
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
This is a massive refactoring PR that changes the whole structure of the crate. Previously it was written like a library
to be used to create the bdk-cli app. But eventually the crate itself became the app. This PR attempts to remove the remaining
lib like patterns in the code, and make it a pure binary crate.
This makes the code more modular and makes it look like a typical binary rust crate.
There was no real good way to structure the change into separate commits, so I made one single big one.. The best way to review is to look at the final structure of the code itself, not the change set.
The crate has following modules now
- `main` : The main app runtime
- `commands`: Includes all the structopt commands used by bdk-cli.
- `handlers`: Include all the command handlers used buy the app.
- `utils`: Include all the utility and helper functions
- `Backend` : Defines the backend node process, and its related methods. (This will be filled more with #92).
Apart from the structure changes there are few other changes that took place
- Almost all of the previous doc comments are removed. As they were written to use bdk-cli as a lib. Instead new structopts "comments" are added to describe the app functionality better. As a result the app `--help` commands are more elaborate and descriptive now. I have also removed few redundant description messages used before, that would mess up the help comments. And as a by product it solves https://github.com/bitcoindevkit/bdk-cli/issues/93.
- bdk is updated to v0.19.0
- bdk-reserves is updated with current version pointing to bdk v0.19.0.
- Default database is now sqlite.
Overall I think I managed not to break anything.
Currently this change will remove most of the previous documentation on the crate. But those aren't useful to context of bdk-cli after this change.. My proposal would be reproduce the README instructions itself in doc.rs landing page.
We also need to update the README to reflect these changes.. I will open that up in a separate PR.
I also haven't updated changelog yet.. Not sure yet how to describe the change in short.. Will do that once this is almost finalized..
### Notes to the reviewers
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [ ] I've added tests for the new feature
* [ ] I've added docs for the new feature
* [ ] I've updated `CHANGELOG.md`
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
Currently the way `ExternalReserves` functionality is written, it can only be used with `electrum` feature. The tests should fail if the implementation behavior is enforced.. Disabling the tests in CI.
Also removing the `regtest-esplora` features from the tests, because they won't work when #92 lands.
### Notes to the reviewers
<!-- In this section you can include notes directed to the reviewers, like explaining why some parts
of the PR were done in a specific way -->
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
I noticed that when I disable default features and don't enable the `repl` feature that the regex tests fail because they need the regex dependency that the `repl` feature brings in. This PR is to simply disable the regex related test code if the `repl` feature isn't enabled.
### Notes to the reviewers
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [ ] I've added tests for the new feature
* [ ] I've added docs for the new feature
* [ ] I've updated `CHANGELOG.md`
#### Bugfixes:
* [ ] This pull request breaks the existing API
* [ ] I've added tests to reproduce the issue which are now passing
* [ ] I'm linking the issue being fixed by this PR
- Add distinct `key-value-db` and `sqlite-db` features, keep default as `key-value-db`
- Put cached wallet data in separate directories: `~/.bdk-bitcoin/<wallet_name>`
- Put compact filter data in `<wallet_name>/compact_filters`
- Depending on the db used put cached wallet data in: `<wallet_name>/wallet.sled/` or `<wallet_name>/wallet.sqlite`
### Notes to the reviewers
This change will help test BDK with different databases, in particular for manually testing DB migrations such as in https://github.com/bitcoindevkit/bdk/pull/502.
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [ ] I've added tests for the new feature
* [x] I've added docs for the new feature
* [x] I've updated `CHANGELOG.md`
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [ ] I've added tests for the new feature
* [ ] I've added docs for the new feature
* [x] I've updated `CHANGELOG.md`
There is still one audit issue that I can't figure out how to fix, I created #85 to track it.
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [ ] I've added tests for the new feature
* [ ] I've added docs for the new feature
* [ ] I've updated `CHANGELOG.md`
#### Bugfixes:
* [ ] This pull request breaks the existing API
* [ ] I've added tests to reproduce the issue which are now passing
* [ ] I'm linking the issue being fixed by this PR
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
Fixes #40
cc @thunderbiscuit
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [ ] I've added tests for the new feature
* [ ] I've added docs for the new feature
* [ ] I've updated `CHANGELOG.md`
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
Fixes https://github.com/bitcoindevkit/bdk-cli/issues/55. I decided to go for one feature flag for each backends as they made dependency management easier. Because different backend will have different dependency, and we don't wanna have redundant ones. Also it makes the commands a little shorter.
### Notes to the reviewers
Right now its not that useful because the backend APIs are not exposed. So I can't really do much other than sync/send in the command line. (unlike testnet we cannot send coins to bdk from outside of local regtest node). So to make it useful in repl mode as described in the issue, we also have to expose the blockchain apis in bdk-cli command in some way (at least the basic stuffs, address, send, generate). Looking for suggestions on this.
usage looks like this:
```
cargo run --features regtest-rpc -- wallet --descriptor "wpkh(tpubEBr4i6yk5nf5DAaJpsi9N2pPYBeJ7fZ5Z9rmN4977iYLCGco1VyjB9tvvuvYtfZzjD5A8igzgw3HeWeeKFmanHYqksqZXYXGsw5zjnj7KM9/*)" sync
{}
```
Although I am having trouble connecting to the esplora end of electrs. Not sure whats the issue, will have to look more.
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [ ] I've added tests for the new feature
* [ ] I've added docs for the new feature
* [x] I've updated `CHANGELOG.md`