Skip to content

Command::visible_long_flag_aliases

since 0.1.0

Add aliases, which function as visible long flag subcommands.

name = "myprog"
[[subcommands]]
name = "test"
long-flag = "test"
visible-long-flag-aliases = ["testing", "testall", "test_all"]
[subcommands.args]
input = { required = false, help = "the file to add" }
Terminal window
prog --testing file.txt
Terminal window
claptrap__subcommand='test'
claptrap_test_input='file.txt'
name = "myprog"
[[subcommands]]
name = "test"
long-flag = "test"
visible-long-flag-aliases = ["testing", "testall", "test_all"]
[subcommands.args]
input = { required = false, help = "the file to add" }
Terminal window
prog --help
Terminal window
Usage: prog [COMMAND]
Commands:
test, --test [aliases: --testing, --testall, --test_all]
help Print this message or the help of the given subcommand(s)
Options:
-h, --help Print help