我们的团队正在考虑实施代码分析作为 TFS 中的签入策略。
我们已经决定要执行哪些规则,但暂时不会将这些策略应用于 TFS,因为我们目前正在迁移到 TFS 2010。
与此同时,开发团队要习惯它并开始删除代码分析警告将开始手动启用代码分析。
那么,有没有一种方法可以让我们发布或自动执行一组规则,而无需手动编辑每个解决方案中每个项目的属性?
Our team are looking into implementing Code Analysis as a check in policy in TFS.
We've decided on which rules we want to enforce but won't be applying the policies to TFS for a while as we are currently migrating to TFS 2010.
In the meantime to get used to it and start removing Code Analysis warnings the dev team are going to start manually enabling Code Analysis.
So, is there a way we can publish or automatically enforce a set of rules without having to manually edit the properties for every project in every solution?
发布评论
评论(1)
要在 VS 2008 中的项目之间共享代码分析设置,请参阅
http://blogs.msdn.com/b/codeanalysis/archive/2006/11/16/faq-how-do-i-share-management-code-analysis-rule-settings-over-多个项目-david-kean.aspx。 (本文是针对 VS 2005 编写的,但相同的方法也适用于 VS 2008。在 VS 2010 中,使用共享规则集文件是更好的方法,尽管可以使用相同的导入目标机制来指定它。)
For sharing Code Analysis settings between projects in VS 2008, see
http://blogs.msdn.com/b/codeanalysis/archive/2006/11/16/faq-how-do-i-share-managed-code-analysis-rule-settings-over-multiple-projects-david-kean.aspx. (The article was written for VS 2005, but the same approach is appropriate in VS 2008 as well. In VS 2010, use of a shared rule set file is a better approach, although it may be specified using the same imported target mechanism.)