RgPublish.exe /source doesn't understand quotes escaped path

Automated deployment for web applications and databases

Moderators: Mike Upton, justin.caldicott, Sean.newham, csmith, chirayu, DavidSimner, david.conlin

RgPublish.exe /source doesn't understand quotes escaped path

Postby abatishchev » Mon Jun 24, 2013 11:57 pm

Having the following parameter in TeamCity build step (.NET runner):

/source="%teamcity.build.checkoutDir%\\MyProj.csproj"

leads to an error:
[02:30:18][Step 7/7] Starting: C:\\TeamCity\\buildAgent\\plugins\\dotnetPlugin\\bin\\JetBrains.BuildServer.NUnitLauncher.exe #TeamCityImplicit
[02:30:18][Step 7/7] in directory: C:\\TeamCity\\buildAgent\\work\\403d3ec57312a972
[02:30:20][Step 7/7] Red Gate Package Publishing Tool version 2.0.4.1
[02:30:20][Step 7/7] Invalid source argument:
[02:30:20][Step 7/7] '"C:\\TeamCity\\buildAgent\\work\\403d3ec57312a972\\MyProject.csproj"' is not a valid path.
[02:30:21][Step 7/7] Process exited with code 1
[02:30:21][Step 7/7] Step RgPublish (.NET Process Runner) failed

Removing quotes (what is unusual for Windows-based development) makes build run fine.
abatishchev
 
Posts: 5
Joined: Mon Jun 24, 2013 11:52 pm
Location: Redmond, WA

Postby james.billings » Tue Jun 25, 2013 6:20 pm

Interesting- if I run RGPublish directly on the command line it does need quotes (if there's a space in the path) as you'd expect.

My guess is that TeamCity implicitly wraps it in quotes internally somehow when passing the parameter?
james.billings
 
Posts: 1144
Joined: Wed Jun 16, 2010 11:10 am
Location: My desk.


Return to Deployment Manager

Who is online

Users browsing this forum: No registered users and 0 guests