-
-
Notifications
You must be signed in to change notification settings - Fork 731
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
Globber exception when using a path with an exclamation #1323
Comments
@stffabi thanks again! |
I wish I had seen this sooner. The fix you really want is to glob-escape it. The resulting glob should be |
@jnm2 ah, I see. Feel free to raise another issue for discussion, and link back to this one. |
@gep13 yes a discussion would be great about this. This also has impact on implementation of #1354. Unfortunately I haven't found any grammar information so far, didn't search for too long up to now. According to https://en.wikipedia.org/wiki/Glob_(programming), Glob allows to have @jnm2 refers to Extglob, which allows an additional syntax with pattern lists, https://www.gnu.org/software/bash/manual/html_node/Pattern-Matching.html. In extglob one can use @jnm2 do you have a link to the grammar? The best basis for a discussion would be to have the grammar for glob/extglob. |
As the globber is one of those pieces you can replace with a module, an alternative breaking way doesn't need to break the default for every Cake user out there, but could rather be an opt-in experience. |
@stffabi That is true. I assumed everyone would want to work with extglob, but if that's not the case, it could be turned on and off. I know that I for one am hoping to be able to share globs between TFS Build vNext (extglob) and Cake, but I wouldn't want to disrupt people who didn't want to use extglob. Best grammar I can find is the bash man page under the Pattern Matching section. |
Well a new globbing paradigm in an external module would make that opt-in & risk free effort. Modules / addins that makes sense for Core/Common can always be promoted later into those in the future. |
I would hope that in the long term future, extglob would be supported OOB since C# developers (especially web developers) will be used to them from tooling across the board. AFAIK everything npm-based is extglob: grunt, gulp, etc. |
What You Are Seeing?
Running a cake script in a folder containing an ! (exclamation) e.g. "C:\Some ! Directory" build.cake throws an exception, "Unknown token"
What is Expected?
Glober should allow to use exclamations in a path.
What version of Cake are you using?
v0.16.2
Are you running on a 32 or 64 bit system?
x64
What environment are you running on? Windows? Linux? Mac?
Windows
Are you running on a CI Server? If so, which one?
TC, but also reproducable locally.
How Did You Get This To Happen? (Steps to Reproduce)
Running the following cake script in a folder with an exclamation, e.g. "C:\Some ! Directory"
Output Log
The text was updated successfully, but these errors were encountered: