-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: allows specifying a short help vs a long help (i.e. varying lev…
…els of detail depending on if -h or --help was used) One can now use `Arg::long_help` which will be displayed when the user runs `--help`. This is typically longer form content and will be displayed using the NextLineHelp methodology. If one specifies the standard `Arg::help` it will be displayed when the user runs `-h` (by default, unless the help short has been overridden). The help text will be displayed in the typical clap fashion. The help format requested (-h/short or --help/long) will be the *default* displayed. Meaning, if one runs `--help` (long) but only an `Arg::help` has been provided, the message from `Arg::help` will be used. Likewise, if one requests `-h` (short) but only `Arg::long_help` was provided, `Arg::long_help` will be displayed appropriately wrapped and aligned. Completion script generation *only* uses `Arg::help` in order to be concise. cc @BurntSushi thanks for the idea!
- Loading branch information
Showing
10 changed files
with
168 additions
and
93 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.