Skip to content
This repository has been archived by the owner on Sep 6, 2021. It is now read-only.

Tools scripts - Need to handle for paths with spaces #6847

Closed
anlawande opened this issue Feb 12, 2014 · 9 comments
Closed

Tools scripts - Need to handle for paths with spaces #6847

anlawande opened this issue Feb 12, 2014 · 9 comments

Comments

@anlawande
Copy link

Got the following error when running the setup_for_hacking.bat

C:\Program Files (x86)\Brackets\brackets>mklink /d "C:\Program Files (x86)\Brackets"\dev C:\Program Files (x86)\Brackets\brackets\
The syntax of the command is incorrect.

Space in the path causes the last argument to break. Will need to be enclosed by quotes.

Problem might possibly extend to all the windows scripts

@peterflynn
Copy link
Member

We should fix the quoting issue, but fyi -- the output above suggests you're passing an incorrect argument to the script (it won't work even once the quoting is fixed). The argument should be pointing to the folder that contains Brackets.exe, which will be different from the folder containing the git source (which includes the setup_for_hacking.bat script itself). In this case, it looks like you're passing the git source folder as the argument instead.

Also, I'd suggest not storing your 'hacking' copy of the source under Program Files, since Windows often applies restrictive permissions to that location, which might make it hard to actually edit the source or pull down updates from git.

@anlawande
Copy link
Author

@peterflynn the paths are valid. I had cloned the git repo in the brackets folder itself.
It was the lack of quotes only causing the problem. Hard coding the path allowed the script to work

@peterflynn
Copy link
Member

@anlawande I would strongly recommend keeping those two locations separate -- it's really asking for trouble when it comes time to run the next sprint's installer. It will also mean your git status is never clean. And if you ever want to build brackets-shell yourself (necessary if you're going to be git pulling unstable master rather than just syncing to the stable sprint-XX tags) this setup isn't really compatible with doing that.

@anlawande
Copy link
Author

will do . Will move my dev copy to my user folder. Thanks for the advice @peterflynn !

@peterflynn
Copy link
Member

No problem -- definitely better to be safe than sorry! :-)

@adalcin
Copy link
Contributor

adalcin commented Feb 13, 2014

I might have fixed this issue with the last commit here: Added brackets around root_path in the mkdir directive of setup_for_hacking.bat #6841

Is that what you're referring to? I had the same problem because my user folder had spaces and I couldn't get the script to run correctly

@anlawande
Copy link
Author

@adalcin yup. thats the one

@RaymondLim
Copy link
Contributor

@adalcin's pull request is already landed in master. @anlawande Can you verify it fixes the issue and close this one.

@anlawande
Copy link
Author

Yup all good now. Working with directories with spaces

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

No branches or pull requests

4 participants