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

Possible RFE: allow spaces in pathnames? #15

Open
ryran opened this issue Jan 27, 2015 · 2 comments
Open

Possible RFE: allow spaces in pathnames? #15

ryran opened this issue Jan 27, 2015 · 2 comments

Comments

@ryran
Copy link
Contributor

ryran commented Jan 27, 2015

Obviously this isn't needed for targetcli itself, but I think it would be one little checkbox to increase the appeal of configshell as a general-use library ....

I haven't taken a crack at it yet -- before I do, could someone (ahem) comment on how feasible it would be? Is anyone violently opposed to this? (I.e., it would mean interpreting quotes and backslashes.)

@agrover
Copy link
Contributor

agrover commented Jan 27, 2015

Sure, this would be very nice to have. I think it might be a straightforward change to our pyparsing-based grammar. @cvubrugier ?

@cvubrugier
Copy link
Collaborator

Yes, we should support spaces in paths.

I see that pyparsing has a QuotedString class. I think that supporting backslashes may be a little bit more difficult though.

@ryan: a while ago, I wrote a test script when I replaced simpleparse with pyparsing to ensure that the new pyparsing-based parser worked like the old simpleparse-based parser:

https://gist.github.com/cvubrugier/6522643

Maybe you can use a similar approach to ensure that your modified pyparsing grammar does not introduce a regression. You can also add test cases with paths that contain spaces.

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

3 participants