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

Fix errors when .bat file path contains paranthesis. #748

Merged
merged 1 commit into from
Mar 6, 2016

Conversation

szdmr
Copy link
Contributor

@szdmr szdmr commented Mar 1, 2016

Without double quotes the path with paranthesis gets evaluated causing an error on Windows systems. Specifically the error text is ".. was unexpected at this time."

I got the error when I moved my Play distro inside a Dropbox folder with name "Dropbox (COMPANYNAME)". The path (COMPANYNAME) part gets evaluated as the if condition clause and makes the batch throw the error above and close.

Double quoting the %CFG_FILE% variable seems to be fixing the error.

Without double quotes the path with paranthesis gets evaluated causing
an error. Specifically "\\\.. was unexpected at this time."
@lightbend-cla-validator
Copy link

Hi @szdmr,

Thank you for your contribution! We really value the time you've taken to put this together.

Before we proceed with reviewing this pull request, please sign the Typesafe Contributors License Agreement:

http://www.lightbend.com/contribute/cla

@szdmr
Copy link
Contributor Author

szdmr commented Mar 1, 2016

FYI I signed the Typesafe Contributors License Agreement.

@muuki88 muuki88 added the windows label Mar 1, 2016
@muuki88
Copy link
Contributor

muuki88 commented Mar 1, 2016

Thanks for your PR. I'm not too familiar with the windows stuff, so
@nazoking @bjuric do you have any objections?

@muuki88
Copy link
Contributor

muuki88 commented Mar 3, 2016

@szdmr on which systems did you test the change? I really would like to merge this change, but we had some rough experiences with the windows bat script :(

@szdmr
Copy link
Contributor Author

szdmr commented Mar 3, 2016

@muuki88 tried it on Windows 8.1 and Windows 10 only, both 64 bits. I don't know if it breaks anything for Windows 8 or below, but do not expect it to do.

It would fail if %CFG_FILE% contained a double quote, but that's impossible as Windows does not let a file or folder to contain double quote in names.

muuki88 added a commit that referenced this pull request Mar 6, 2016
Fix errors when .bat file path contains paranthesis.
@muuki88 muuki88 merged commit fd3d9cf into sbt:master Mar 6, 2016
@muuki88
Copy link
Contributor

muuki88 commented Mar 6, 2016

thanks for the clarification 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants