Skip to content
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

Handle double quoted arguments in argv #3

Open
kalhartt opened this issue Oct 1, 2014 · 1 comment
Open

Handle double quoted arguments in argv #3

kalhartt opened this issue Oct 1, 2014 · 1 comment

Comments

@kalhartt
Copy link

kalhartt commented Oct 1, 2014

It seems the argv form is passed directly to docopt as a string with no tokenizing, breaking double quoted arguments. An example here.

Maybe wrap this in shlex.split or something similar?

@keleshev
Copy link
Member

Sorry for late reply.

Pull request is welcome.

mikebryant added a commit to mikebryant/try.docopt.org that referenced this issue May 6, 2016
Allow the use of quoted arguments, e.g.
```
Usage:
  test <arg1> <arg2>
```
with the input `a "b c d"`

If tokenization fails, fall back to the original behaviour
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants