From b8ceab3e6f75d598b7323fb54b2e4dbbb234a60b Mon Sep 17 00:00:00 2001 From: Pavan Kumar Sunkara Date: Sat, 4 Sep 2021 15:04:09 +0530 Subject: [PATCH] Fixes #2736 --- README.md | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 1cf7bcb8..011ebeff 100644 --- a/README.md +++ b/README.md @@ -330,7 +330,7 @@ args: index: 1 - verbose: short: v - multiple: true + multiple_occurrences: true about: Sets the level of verbosity subcommands: - test: @@ -340,7 +340,8 @@ subcommands: args: - debug: short: d - about: print debug information + long: debug + about: Print debug information ``` Since this feature requires additional dependencies that not everyone may want, it is *not* compiled in by default and we need to enable a feature flag in Cargo.toml: @@ -383,14 +384,14 @@ fn main() { (version: "1.0") (author: "Kevin K. ") (about: "Does awesome things") - (@arg CONFIG: -c --config +takes_value "Sets a custom config file") + (@arg CONFIG: -c --config [FILE] "Sets a custom config file") (@arg INPUT: +required "Sets the input file to use") - (@arg verbose: -v --verbose "Print test information verbosely") + (@arg verbose: -v --verbose "Sets the level of verbosity") (@subcommand test => (about: "controls testing features") (version: "1.3") (author: "Someone E. ") - (@arg debug: -d ... "Sets the level of debugging information") + (@arg debug: -d --debug "Print debug information") ) ).get_matches();