views:

30

answers:

1

TFS 2008, VS 2008. I have a tfsbuild.proj and tfsbuild.msp file in $/MyStuff/TeamBuildTypes/Dev folder. I have a targets file at $/MyStuff/TeamBuildTypes/IncludeFiles/Common/test.xml. test.xml contains an XML fragment that overrides the BeforeGet task.

I tried to get the file into my tfsbuild.proj file like this:

<Import Project="$/MyStuff/TeamBuildTypes/IncludeFiles/Common/test.xml" />

The build fails because it tries to get the file from a relative path that is way off.

I have shifted gears a little and am now trying an Exec task to get the file from TFS into the local filesystem.

<Exec WorkingDirectory="$(SolutionRoot)" Command="&quot;$(TF)&quot; get &quot;$/MyStuff/TeamBuildTypes/IncludeFiles/Common/test.xml&quot; /version:W$(WorkSpaceName) /overwrite /force /noprompt /recursive" IgnoreExitCode="true" />

I have no idea where the file is going. I don't get an error. I have access to the $(SolutionRoot) variable but the TeamBuildTypes folder is above that one in the filesystem. How can I get to this file and use it as an overrride to my task for the current build?

Help?

Thanks!

+1  A: 

That's not a "remote" path. It's a path into TFS source control. It can only be understood by TFS.

MSBUILD is not part of TFS - it's part of the .NET SDK. It can only understand the kind of paths all programs can understand.

You'll have to fetch this file from source control onto the build machine, and reference it with a path to where you fetched it.

John Saunders