I'm working with Microsoft Team Foundation Server and MSDN has been fantastic so far with providing all the information I've needed and so much more--except in one spot.
I'm creating an automated build and under Workspace > Working Folders > Build Agent Folder, it has "$(SourceDir)" as default.
I can't seem to figure out what that is actually referencing. Is it pointing toward the folder that the solution is in, or something else?
This is well explained in this article: List of variables like $(SourceDir).
For the workspace mapping dialog you can only use two variables to help with expansion:
$(BuildDir) - Expands to BuildAgent.BuildDirectory
$(SourceDir) - Expands to $(BuildDir)\Sources by default
The directory "Sources" is not hard-coded and may be changed by modifying the TfsBuildService.exe.config file on the build agent. If you open that file there will be an application setting called "SourcesSubDirectory". If you need a shorter path you may change this key to something like "s" instead of "Sources". If you made this change then the $(SourceDir) variable would expand to $(BuildDir)\s.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With