-
-
Notifications
You must be signed in to change notification settings - Fork 62
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ARG_OPTIONAL_REPEATED always appends to the defaults rather than replacing #12
Comments
Hello, |
Well, in my particular case, I was attempting to create an option that would tell a script to operate on multiple architectures of sample data. I wanted to be able to set a default that it would run on all the architectures that we support, but to be able to set a reduced number (possibly only one) at the command-line, primarily for debugging (so I wouldn't have to wait for the script to process through all of them at once). Perhaps when using |
If you are curious, the example I was working on is here: For now, I'm leaving it blank and adding the values I need at the command line. But I'd prefer to be able to set the defaults. |
You have a good point, I will think about it. |
The issue is technically fixed (by added documentation), but see #13 for the proper fix. |
The documentation for ARG_OPTIONAL_REPEATED reads:
The other options for argbash will supersede their defaults, but the effect of using the default option in ARG_OPTIONAL_REPEATED means that this set of values will always be present in the resulting list and that the arguments specified at the command-line merely supplement them.
Either the documentation should reflect this behavior or it should be changed to behave more similarly to the other options.
The text was updated successfully, but these errors were encountered: