rust-lang / cargo-bisect-rustc

Bisects rustc, either nightlies or CI artifacts
https://rust-lang.github.io/cargo-bisect-rustc/
Apache License 2.0
177 stars 55 forks source link

Fix the CLI requiring the help argument #206

Closed Alexendoo closed 2 years ago

Alexendoo commented 2 years ago

Currently the CLI on master requires the help flag to be passed:

$ cargo bisect-rustc
error: The following required argument was not provided: help

USAGE:
    cargo <SUBCOMMAND>

For more information try help
$ cargo-bisect-rustc
error: The following required argument was not provided: help

USAGE:
    cargo bisect-rustc [OPTIONS] [-- <COMMAND_ARGS>...]

For more information try --help

I copied what https://github.com/clap-rs/clap/blob/master/examples/cargo-example.rs does, with this the help message of cargo-bisect-rustc --help is slightly different:

cargo-bisect-rustc 

USAGE:
    cargo <SUBCOMMAND>

OPTIONS:
    -h, --help    Print help information

SUBCOMMANDS:
    bisect-rustc    Bisects rustc toolchains with rustup
    help            Print this message or the help of the given subcommand(s)

But cargo bisect-rustc --help works as normal