简体   繁体   中英

TFS 2010 build - Reference build path using invokeprocess

Edit after Mike z reploy

I need to get the string of the path were the Source files are downloaded to the build server from source control. I believe that is called SourcesDirectory.

I've added an invokeprocess activity that calls a powershell script that prints out whatever you pass to the parameter "message". What i need is the name of the variable that holds the binaries directory to pass it to the powershell script (later on i will do more stuff with this variable, of course)

This is how my invokeprocess expression editor looks like:

String.Format(" ""& '{0}' -message '{1}' "" ", "D:\\scripts\\test.ps1", [placeholder])

All i need is to replace the placeholder with the variable that hold the binaries path (not the drop files) on the build server

Thx!

Thx to mike Z's reploy i was able to know that the variable i was looking for was "SourcesDirectory".

To be able to see this variable i had to add the activity inside the "Run on agent" process.

I was not seeing "SourcesDirectory" because i was adding my "Invoke Process" outside "Run on agent".

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM