问题描述
环境:VS 2008 9.0.30729.4108 QFE,C#
我有一个包含46个项目的解决方案.构建后,无需重新构建Visual Studio,我可以运行任意次数.如果我只在一个类中插入一个空格字符,然后保存该文件并按F5键,它将开始构建并 最后给我这个:
===========内部版本:32个成功,0个失败,8个最新,跳过0个==========
为什么?可以预防吗?对于具有空格符的一个项目需要重建,我并不感到惊讶,但是为什么所有32个依赖或间接依赖于已更改项目的项目(我假设这些依赖项 是什么原因?)
基于下面提到的帖子,我先构建了Diagnostic输出(300,000行),然后进行了详细说明.第二个仍然有43,500行.我不确定要寻找什么来确定为什么要构建这32个项目.
我不认为在在构建中,仅构建已更改的项目"之类的地方有个不错的选择???
以下是一个相关链接,但并未完全回答该问题,如果可能的话,我将不胜感激.
http://social.msdn.microsoft.com/forums/zh-CN/msbuild/thread/59812f3a-8d06-4ace-aef3-9920a699d3ed
谢谢
Environment: VS 2008 9.0.30729.4108 QFE, C#
I have a solution with 46 projects. After a build, I can run as many times as I want without Visual Studio rebuilding. If I insert nothing more than a single space character into a class, then save that file and press F5, it starts a build and gives me this at the end:
========== Build: 32 succeeded, 0 failed, 8 up-to-date, 0 skipped ==========
Why? Can this be prevented? I'm not surprised that the one project that got the space character requires a rebuild, but why all 32 projects that are dependent or indirectly dependent on the one that was changed (I'm assuming those dependencies are the reason)?
Based on the post mentioned below, I built with Diagnostic output (300,000 lines) then Detailed. The 2nd still had 43,500 lines. I'm not sure what to look for to determine why those 32 projects get built.
I don't suppose there's a nice option somewhere like "On Build, only build projects that have changed"??
The following is a related link, but doesn't fully answer the question and I would appreciate a little guidance if possible:
http://social.msdn.microsoft.com/forums/en-US/msbuild/thread/59812f3a-8d06-4ace-aef3-9920a699d3ed
Thanks
这篇关于您如何防止构建未更改的项目?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!