-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Add support for comma separated values #348
Comments
I'm going to start looking at this. I'll ping you back if I have questions! |
👍 |
You should be able to look at the |
Hey! Sorry for the late reply, it's been a little busy for me lately. I had the chance to work on this a little this weekend. I have a few questions! Would introducing something like this be on the right path (notice let matches = App::new("MyApp")
.arg(Arg::with_name("input")
.help("the input file to use")
.takes_value(true)
.short("i")
.long("input")
.multiple(true)
.takes_list(true)
.required(true)
.conflicts_with("output"))
.get_matches(); So let's say this implementation works. When we're asking for |
No problem! 👍 Assuming the user runs For this issue, you shouldn't have to worry about anything in But you bring up a very interesting idea, that I like. Changing your Another setting that would go along very nicely with this is making the delimiter selectable but defaulting to For the above two features though I will create two issues, instead of trying to solve all three in this one issue. |
@psyomn How's it going? |
Hey, sorry for disappearing! I haven't had a chance to work on clap these Thank you for the extensive writeup by the way. I wanted to express my Hope everything is well on your end! On Fri, Dec 18, 2015 at 3:58 AM, Kevin K. [email protected] wrote:
|
No worries :) Just wanted to check up. We may go ahead and implement this, but if its still open when your time frees up feel free to keep at it and put in a PR or ask if you have questions 😉 |
This commit adds support for values separated by commas such as --option=val1,val2,val3. It also includes support for uses without the equals and shorts (both with and without) --option=val1,val2 --option val1,val2 -oval1,val2 -o=val1,val2 -o val1,val2 Closes #348
Closed with #387 |
This commit adds support for values separated by commas such as --option=val1,val2,val3. It also includes support for uses without the equals and shorts (both with and without) --option=val1,val2 --option val1,val2 -oval1,val2 -o=val1,val2 -o val1,val2 Closes #348
This commit adds support for values separated by commas such as --option=val1,val2,val3. It also includes support for uses without the equals and shorts (both with and without) --option=val1,val2 --option val1,val2 -oval1,val2 -o=val1,val2 -o val1,val2 Closes #348
Example, these should all parse to exactly the same matches
The text was updated successfully, but these errors were encountered: