TFS构建失败,并显示“无法复制文件".文件甚至不在项目中 [英] TFS Build fails with "Could not copy file" of file not even in the project

查看:92
本文介绍了TFS构建失败,并显示“无法复制文件".文件甚至不在项目中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经设置了TFS Build,直到昨天为止一切正常.从那以后,我从一个项目中收到以下错误:

I have TFS Build set up, which worked fine until yesterday. Since then I get the following error from one project:

C:\ Program Files(x86)\ MSBuild \ Microsoft \ VisualStudio \ v11.0 \ WebApplications \ Microsoft.WebApplication.targets (182):无法复制文件 "Content \ themes \ base \ images \ ui-bg_flat_0_aaaaaa_40x100.png",因为它 没找到.

C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v11.0\WebApplications\Microsoft.WebApplication.targets (182): Could not copy the file "Content\themes\base\images\ui-bg_flat_0_aaaaaa_40x100.png" because it was not found.

C:\ Program Files(x86)\ MSBuild \ Microsoft \ VisualStudio \ v11.0 \ WebApplications \ Microsoft.WebApplication.targets (182):无法复制文件 "Content \ themes \ base \ images \ ui-bg_flat_75_ffffff_40x100.png"是因为 找不到. C:\ Program档案 (x86)\ MSBuild \ Microsoft \ VisualStudio \ v11.0 \ WebApplications \ Microsoft.WebApplication.targets (182):无法复制文件 "Content \ themes \ base \ images \ ui-bg_glass_55_fbf9ee_1x400.png"是因为 找不到.

C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v11.0\WebApplications\Microsoft.WebApplication.targets (182): Could not copy the file "Content\themes\base\images\ui-bg_flat_75_ffffff_40x100.png" because it was not found. C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v11.0\WebApplications\Microsoft.WebApplication.targets (182): Could not copy the file "Content\themes\base\images\ui-bg_glass_55_fbf9ee_1x400.png" because it was not found.

C:\ Program文件 (x86)\ MSBuild \ Microsoft \ VisualStudio \ v11.0 \ WebApplications \ Microsoft.WebApplication.targets (182):无法复制文件 "Content \ themes \ base \ images \ ui-bg_glass_65_ffffff_1x400.png"是因为 找不到. C:\ Program Files

C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v11.0\WebApplications\Microsoft.WebApplication.targets (182): Could not copy the file "Content\themes\base\images\ui-bg_glass_65_ffffff_1x400.png" because it was not found. C:\Program Files

...还有大约10个...

...and about 10 more...

该错误提到的文件在项目中或项目的任何文件夹中都找不到.

The files mentioned by the error are nowhere to be found, not in the project nor in any folder of the project.

有人知道如何消除此错误吗?

.target文件的Ln 182处是:

At Ln 182 of the .target file is the following:

<Copy SourceFiles="@(Content)" Condition="'%(Content.Link)' == ''"
DestinationFolder="$(WebProjectOutputDir)\%(Content.RelativeDir)" 
SkipUnchangedFiles="true" 
Retries="$(CopyRetryCount)"
RetryDelayMilliseconds="$(CopyRetryDelayMilliseconds)" />

我在解决方案中还有另一个项目,该项目几乎相同并且构建良好.

I also have a second project in the solution which is nearly the same and builds fine.

推荐答案

Grep/在整个源代码树中搜索那些文件名-必须引用它们.

Grep/Search the entire source tree for those filenames - something must be referencing them.

这篇关于TFS构建失败,并显示“无法复制文件".文件甚至不在项目中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆