相关疑难解决方法(0)

如何更改MSBuild在Team Foundation Build下使用的构建目录?

尝试使用Team Foundation Build构建我的应用程序时出现以下错误:

C:\ WINDOWS\Microsoft.NET\Framework\v3.5\Microsoft.Common.targets(1682,9):错误MSB3554:无法写入输出文件"obj\Release\Company.Redacted.BlahBlah.Localization.Subsystems. Startup_Shutdown_Processing.StartupShutdownProcessingMessages.de.resources".指定的路径,文件名或两者都太长.完全限定的文件名必须少于260个字符,目录名必须少于248个字符.

我的项目在我的开发机器上构建良好,因为源只有两个文件夹深,但TF Build似乎使用了一个非常深的目录导致它中断.如何更改使用的文件夹?

编辑:我检查了存储在源代码管理中的构建的.proj文件,发现了以下内容:

<!--  BUILD DIRECTORY
 This property is included only for backwards compatibility. The build directory used for a build 
 definition is now stored in the database, as the BuildDirectory property of the definition's 
 DefaultBuildAgent. For compatibility with V1 clients, keep this property in sync with the value 
 in the database.
-->
<BuildDirectoryPath>UNKNOWN</BuildDirectoryPath>
Run Code Online (Sandbox Code Playgroud)

如果这存储在数据库中,我该如何更改它?

编辑:找到以下博客文章,可能指向我的解决方案.现在我只需要弄清楚如何更改Build Agent中的设置. http://blogs.msdn.com/jpricket/archive/2007/04/30/build-type-builddirectorypath-build-agent-working-directory.aspx

目前我的工作目录是"$(Temp)\ $(BuildDefinitionPath)",但现在我不知道哪些通配符可用于指定不同的文件夹.

msbuild tfs tfsbuild

8
推荐指数
1
解决办法
1万
查看次数

标签 统计

msbuild ×1

tfs ×1

tfsbuild ×1