Command::long_flag
long_flag
Section titled “long_flag ”Sets the long version of the subcommand flag without the preceding --
.
Example
Section titled “Example”name = "myprog"[[subcommands]]name = "sync"long-flag = "sync"[subcommands.args]search = { short = 's', long = "search", action = "set-true", help = "search remote repositories for matching stringsg" }
name: myprogsubcommands:- name: sync long-flag: sync args: search: short: s long: search action: set-true help: search remote repositories for matching stringsg
{ "name": "myprog", "subcommands": [ { "name": "sync", "long-flag": "sync", "args": { "search": { "short": "s", "long": "search", "action": "set-true", "help": "search remote repositories for matching stringsg" } } } ]}
myprog --sync --search
Output
Section titled “Output”claptrap__subcommand='sync'claptrap_sync_search='true'