mirror of
https://github.com/fish-shell/fish-shell.git
synced 2025-02-23 22:27:23 +08:00

This implements a `fish_opt` command that provides a way for people to create option specs for the `argparse` command as an alternative to creating such strings by hand. Fixes #4190
20 lines
446 B
Plaintext
20 lines
446 B
Plaintext
# bool, short only
|
|
h
|
|
# bool, short and long
|
|
h/help
|
|
# bool, short and long but the short var cannot be used
|
|
h-help
|
|
# required val, short and long but the short var cannot be used
|
|
h-help=
|
|
# optional val, short and long valid
|
|
h/help=?
|
|
# optional val, short and long but the short var cannot be used
|
|
h-help=?
|
|
# repeated val, short and long valid
|
|
h/help=+
|
|
# repeated val, short and long but short not valid
|
|
h-help=+
|
|
# repeated val, short only
|
|
h=+
|
|
h=+
|