I have a job which uses the nant job runner. I tried this with the batch runner as wel and got the same results.
Some of the properties I'm passing in to nant have spaces ( filepaths ). I quote the values but for some reason it's inserting extra quotes.
This is the cmdline:
-D:source.base.dir="%system.source.base.dir%" -D:target.base.dir="%system.target.base.dir%" -D:project.build.filters="%system.project.build.filters%"
the system variable target.base.dir is defined like so: \\gcm-td4\c$\Program Files\GRAS Service Test
Looks like TeamCity is parsing my cmdline and sticking in arbitrary quotes which screws up the value for target.base.dir for nant. Here's what actually get's executed:
Starting: C:\TeamCity\buildAgent\work\82146f8c47cda3a7\nant\bin\NAnt.exe -buildfile:C:\TeamCity\buildAgent\work\82146f8c47cda3a7\build\service.deploy.build -extension:C:\TeamCity\buildAgent\plugins\dotnetPlugin\bin\JetBrains.BuildServer.NAntLoggers.dll -listener:JetBrains.BuildServer.NAntLoggers.NAntListener -D:source.base.dir="C:\TeamCity\buildAgent\work\82146f8c47cda3a7\deploy" "-D:target.base.dir="\\gcm-td4\c$\Program Files\GRAS Service Test"" -D:project.build.filters="C:\TeamCity\buildAgent\work\82146f8c47cda3a7\filters" deploy
This breaks nant. Please advise.