You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As documented in paragraph 3.7, "From picocli 2.0, positional parameters can be specified anywhere on the command line, they no longer need to follow the options." Is it possible with PicoCLI 4.x to create the original behavior or something similar?
Want this to work "command -a X -version 1.2 -- --optA --optB=4".
Want this to fail "command -a X -version 1 2 -- --optA --optB=4". (user typo'd the decimal for option "version")
The parameters are declared like @parameters
List extraParamaters;
but this prevents the parser from catching the typo. If I want all parameters to come after options or even after --, is it possible to configure the framework to do this? If so, I would expect the parser to catch that the "2" is a mismatched parameter, right?
The text was updated successfully, but these errors were encountered:
Currently, the -- End Of Options delimiter only means that what follows are positional parameters, but that doesn't prevent that some of the preceding arguments may also be positional parameters.
Your feature request is to introduce a parser configuration that results in an error message if any positional parameters are found prior to the -- End Of Options delimiter, or when any positional parameters are found without the -- End Of Options delimiter being present.
I don’t oppose this, but I won’t have time to work on this myself. Will you be able to provide a pull request with tests for this?
As documented in paragraph 3.7, "From picocli 2.0, positional parameters can be specified anywhere on the command line, they no longer need to follow the options." Is it possible with PicoCLI 4.x to create the original behavior or something similar?
Want this to work "command -a X -version 1.2 -- --optA --optB=4".
Want this to fail "command -a X -version 1 2 -- --optA --optB=4". (user typo'd the decimal for option "version")
The parameters are declared like
@parameters
List extraParamaters;
but this prevents the parser from catching the typo. If I want all parameters to come after options or even after --, is it possible to configure the framework to do this? If so, I would expect the parser to catch that the "2" is a mismatched parameter, right?
The text was updated successfully, but these errors were encountered: