bitcoindevkit / bdk-cli

A CLI wallet library and REPL tool to demo and test the BDK library
Other
108 stars 64 forks source link

Fix repl and wallet help docs #69

Closed notmandatory closed 2 years ago

notmandatory commented 2 years ago

Description

This fixes the help docs for the repl and wallet subcommands. The repl subcommand was showing the proxy options docs instead, and the wallet subcommand was showing the description from the WalletSubCommand enum.

This is a workaround for structopt issue #333, #391, #418; see https://github.com/TeXitoi/structopt/issues/333#issuecomment-712265332

Notes to the reviewers

Before this PR this was showing:

$ cargo run --features esplora-ureq,compiler -- --help
...
SUBCOMMANDS:
    compile    Compile a miniscript policy to an output descriptor
    help       Prints this message or the help of the given subcommand(s)
    key        Key management sub-commands
    repl       Proxy Server options
    wallet     Wallet sub-commands

After this PR we get:

$ cargo run --features esplora-ureq,compiler -- --help
...
SUBCOMMANDS:
    compile    Compile a miniscript policy to an output descriptor
    help       Prints this message or the help of the given subcommand(s)
    key        Key management sub-commands
    repl       Enter REPL command loop mode
    wallet     Wallet options and sub-commands

Checklists

All Submissions:

Bugfixes:

notmandatory commented 2 years ago

I also had to pin the version of fd-lock to version 3.0.2 to resolve an error when building with rust +1.46.0.