I’m trying to set up a build definition in TFS 2010. The options for this seem very limited, for instance I have 5 solution files in my source control and I don’t seem to be able to specifiy which one to use. I’ve selected a workspace from my deployment server (which does a TF get every 10 minutes so I know it’s a valid workspace), but when the build runs it gives me an error complaining about the mapping – and it seems to have made it’s own mapping up from somewhere.
Mapping I set: $/InteractV4/Dev/IV4ProductionSR/
Error: There is no working folder mapping for $/InteractV4/Dev/IV4Support/iv4ProductionSR.sln.
There are 2 issues with this error. 1: it’s not the workspace I was trying to use. 2: It’s wrong and there is a working folder mapping for this source, both on my local PC and on the deployment pc, but NOT on the build server. Do I need to set up a load of folders and mappings on the build agent server? Or on the main TFS (source) server?
Thanks.
TFS-Builds operate on private Workspaces that get generated during the build process, so using a custom-Workspace is without tweaking impossible.
It’s possible to keep TFS from regenerating a new Workspace with each Buid, by going to Build Definition edit “Process”:”2.Basic”:”Clean Workspace” and changing default value
Allinto eitherOutputsorNone.The mappings are set for each Build Defition where various pairs exist:
The

$(SourceDir)is substituted during Build and it gets its value from the Build Agent Settings. If you go to the TFS Admin Console & select “Build Configuration”, you ‘ll be presented with a list of Build Agents running on the Server (there might be additional Agents in other Servers). Clicking on “Properties” of an Agent, pops up a Window like that:This entry “Working directory” is the one that resolves & substitutes
$(SourceDir)during build.For example, an entry
$(SystemDrive)\Builds\$(BuildAgentId)could resolve into something likeC:\Builds\88.So, for a TFS Build running on this Agent, you should expect all Sources that stand in source control under
$/foo/barto be found underC:\Builds\88\somewhereEDIT
According to your comments you have now a mapping like this:
Your build fails, as “There is no working folder mapping for $/InteractV4/Dev/IV4Support/iv4ProductionSR.sln”.
Is this source control directory
$/InteractV4/Dev/IV4Supportmapped in your Build Definition?