Multiple commands match your selection:
0. my-cli foo
1. my-cli foo one
2. my-cli foo two
Run again with -h=<index> to see the longer details of any of those commands.
How?
This PR adds a new possible transition in the state machine.
For every part of a path (except the last one), -h/--help can now be passed as a leaf.
Said differently: nothing is allowed after -h/--help when it breaks a path apart.
Let a command be foo bar baz --arg #0 (i.e. paths = [["foo", "bar", "baz"]]):
foo --help would now be allowed
foo bar --help would now be allowed
foo bar baz --help --arg aaa would still be allowed
foo bar baz --arg aaa --help would still be allowed
foo --help bar baz --arg aaa would NOT be allowed
stateDiagram-v2
foo
state "--help (new)" as h1
foo --> h1
foo --> bar
bar
state "--help (new)" as h2
bar --> h2
bar --> baz
baz
state "--help" as h3
baz --> h3
Closes #110
This PR adds new possible outputs for
-h
/--help
.my-cli foo --help
can now return:How?
This PR adds a new possible transition in the state machine.
For every part of a
path
(except the last one),-h
/--help
can now be passed as a leaf. Said differently: nothing is allowed after-h
/--help
when it breaks apath
apart.Let a command be
foo bar baz --arg #0
(i.e.paths = [["foo", "bar", "baz"]]
):foo --help
would now be allowedfoo bar --help
would now be allowedfoo bar baz --help --arg aaa
would still be allowedfoo bar baz --arg aaa --help
would still be allowedfoo --help bar baz --arg aaa
would NOT be allowed