You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ssokolow@monolith rdbackup-excludes-indexer [master] %% cargo profiler
error: Invalid profiler. cargo profiler currently supports callgrind and cachegrind.
Referring to "no profiler" as an invalid profiler is one of those things that only makes sense to a computer.
The error message should be one of the following in this case:
error: You must specify a profiler.
USAGE: cargo profiler <SUBCOMMAND>
The output of cargo profiler --help
Also, I noticed that your actual USAGE: doesn't use < and > to specify that the subcommand is mandatory.
I can't double-check, since I get an error in rustc-serialize when I attempt to build your git HEAD, but I think you can just add .required(true) to the subcommand argument to get a more helpful error message automatically, plus the appropriate <SUBCOMMAND> in your --help rather than [SUBCOMMAND].
(I'm not 100% certain because I use subcommands infrequently enough in my projects that the last time I defined one was back when clap didn't exist and I was working with argparse and Python.)
The text was updated successfully, but these errors were encountered:
Referring to "no profiler" as an invalid profiler is one of those things that only makes sense to a computer.
The error message should be one of the following in this case:
error: You must specify a profiler.
USAGE: cargo profiler <SUBCOMMAND>
cargo profiler --help
Also, I noticed that your actual
USAGE:
doesn't use<
and>
to specify that the subcommand is mandatory.I can't double-check, since I get an error in
rustc-serialize
when I attempt to build your gitHEAD
, but I think you can just add.required(true)
to the subcommand argument to get a more helpful error message automatically, plus the appropriate<SUBCOMMAND>
in your--help
rather than[SUBCOMMAND]
.(I'm not 100% certain because I use subcommands infrequently enough in my projects that the last time I defined one was back when clap didn't exist and I was working with
argparse
and Python.)The text was updated successfully, but these errors were encountered: