Python CLI libraries analysis
An analysis of several Python CLI libraries to detect their usability in various cases.
Usecase
We want to design a command with following usage based on compilation of several existing commands:
Usage: testcli [options] [--choices=VALUE]... [--params=...] create <label>
testcli [options] [--choices=VALUE]... [--params=...] drop <label>
testcli -h | --help
testcli --version
Options:
-h, --help Show this help message and exit.
--version Show program's version number and exit.
--config=FILE Set config file.
--string=STRING Set custom string.
--number=NUMBER Set custom number.
--params=KEY=VALUE Set custom parameters.
--today=DATE Set custom today [default: today].
--choices=VALUE Set custom choices [default: all]. Available options: 'all', 'foo', 'bar', 'baz'.
-n, --dry-run Don't actually do anything.
-v,--verbosity=LEVEL Set verbosity level in range 0 to 3 [default: 1].