mirror of
https://github.com/clap-rs/clap
synced 2024-12-12 13:52:34 +00:00
4e9f3cca2c
Inspired by rust-lang/cargo#11159
560 B
560 B
$ 03_01_flag_bool --help
A simple to use, efficient, and full-featured Command Line Argument Parser
Usage: 03_01_flag_bool[EXE] [OPTIONS]
Options:
-v, --verbose
-h, --help Print help information
-V, --version Print version information
$ 03_01_flag_bool
verbose: false
$ 03_01_flag_bool --verbose
verbose: true
$ 03_01_flag_bool --verbose --verbose
? failed
error: The argument '--verbose' was provided more than once, but cannot be used multiple times
Usage: 03_01_flag_bool[EXE] [OPTIONS]
For more information try '--help'