Runtime: sync.cmd / build.cmd commandlets fail when a space is in the path

Created on 17 May 2017  路  6Comments  路  Source: dotnet/runtime

I know, why on earth would you use a space a file path, but I happen to have the path: \myprojects\vs.net projects\github\corefx which makes sync.cmd and build.cmd fail as they don't wrap the path they're in with quotes.

Moving the repo on disk to a folder without a space solves it. Not a high-prio error, just a FYI in case you didn't know. The https://github.com/dotnet/corefx/wiki/Checking-out-the-code-repository page would likely benefit from a warning in this case, so people who clone the repo and try to build it aren't surprised if they're as daft as me and use a space in the path their cloned repo is located ;)

area-Infrastructure-libraries bug up-for-grabs

Most helpful comment

@karelz thanks, will update the wiki next time and pop in the gitter room :)

All 6 comments

I had the same thing. Example, I use Box, and you will have a directory structure

C:\Users\me\Box Sync\corefx

Again I moved to root of C: with no spaces and works.

Thanks for catching it @FransBouma! I updated the wiki page. Next time, feel free to make the edits as well - it is RW for everyone and bunch of us are partying on the wiki, collaborating in a gitter room ...

@karelz thanks, will update the wiki next time and pop in the gitter room :)

@weshaggard I didn't check, do you think that's still happening?

There is likely a good chance it still happens unless someone explicitly fixed it. However with the engineering system changes coming sync will no longer exist as a separate script and build will be going through a new pipeline which hopefully handles this a little better. It is worth verifying that build works correctly with spaces in the repo path.

Build still fails from a path with a space in it.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

EgorBo picture EgorBo  路  3Comments

jamesqo picture jamesqo  路  3Comments

bencz picture bencz  路  3Comments

Timovzl picture Timovzl  路  3Comments

noahfalk picture noahfalk  路  3Comments