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
adding allow_hyphen_values: true to the argument; and
prepending -- to the argument list in the invocation: ./test -- '--value'
I tried both separately before but not jointly.
I'm leaving this issue open because I think it would be nice to provide an example that illustrate this.
I think Slap is underrated and deserves a much wider audience, but much of them might not find it straightforward to use Clap's documentation. Adding more examples would definitely make a difference.
ngirard
changed the title
Error when value of argument starts with --
Document how to allow arguments start with hyphens
Nov 6, 2020
ngirard
changed the title
Document how to allow arguments start with hyphens
Document how to allow arguments to start with hyphens
Nov 6, 2020
I think it would be cool also to have some editor intellisense support, so you can see available options and what they do. See #10
This is doable because in clap's master there is a JSON schema we can use: https://github.com/clap-rs/clap/blob/master/clap.schema.json
Using the following test script:
Executing
./test value
outputsvar:value
, but executing `./test '--value' leads toIn my scenario I need to be able to have arguments that start with
--
.Is there a workaround ?
The text was updated successfully, but these errors were encountered: