我们正在试用 Visual Studio 11 Beta。一切都很好,除了我们无法在不忽略几个 checkin 策略失败的情况下 checkin 文件。例如:
Internal error in Changeset Comments Policy. Error loading the Changeset Comments Policy policy (The policy assembly 'Microsoft.TeamFoundation.PowerTools.CheckinPolicies.ChangesetComments, Version=8.1.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' is not registered.). Installation instructions: To install this policy, follow the instructions in CheckForComments.cs.
我们正在使用 TFS Power Tools 中的一些 checkin 策略。它们显然在 Visual Studio 10 中工作得很好。但我也需要让它们在 VS11 中工作。我尝试添加注册表项来注册 Visual Studio 11 的策略:
我还尝试将多个绑定(bind)重定向添加到 devenv.exe.config 文件,因为这些 TFS Power Tools 策略程序集引用了 Visual Studio 10 程序集。
<dependentAssembly>
<assemblyIdentity name="Microsoft.TeamFoundation.WorkItemTracking.Client" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="10.0.0.0-99.9.0.0" newVersion="11.0.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.TeamFoundation.VersionControl.Common.Integration" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/>
<bindingRedirect oldVersion="10.0.0.0-99.9.0.0" newVersion="11.0.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.TeamFoundation" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/>
<bindingRedirect oldVersion="10.0.0.0-99.9.0.0" newVersion="11.0.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.TeamFoundation.Common.Library" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/>
<bindingRedirect oldVersion="10.0.0.0-99.9.0.0" newVersion="11.0.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.TeamFoundation.WorkItemTracking.Client.DataStore" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/>
<bindingRedirect oldVersion="10.0.0.0-99.9.0.0" newVersion="11.0.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.TeamFoundation.WorkItemTracking.Proxy" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/>
<bindingRedirect oldVersion="10.0.0.0-99.9.0.0" newVersion="11.0.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.TeamFoundation.WorkItemTracking.Client.Cache" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/>
<bindingRedirect oldVersion="10.0.0.0-99.9.0.0" newVersion="11.0.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.TeamFoundation.WorkItemTracking.Client.RuleEngine" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/>
<bindingRedirect oldVersion="10.0.0.0-99.9.0.0" newVersion="11.0.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.TeamFoundation.WorkItemTracking.Client.Provision" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/>
<bindingRedirect oldVersion="10.0.0.0-99.9.0.0" newVersion="11.0.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.TeamFoundation.WorkItemTracking.Client.QueryLanguage" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/>
<bindingRedirect oldVersion="10.0.0.0-99.9.0.0" newVersion="11.0.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.TeamFoundation.PowerTools.CheckinPolicies.ChangesetComments" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/>
<bindingRedirect oldVersion="8.1.0.0-9.9.0.0" newVersion="10.0.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.TeamFoundation.PowerTools.CheckinPolicies.CustomPathPolicy" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/>
<bindingRedirect oldVersion="8.1.0.0-9.9.0.0" newVersion="10.0.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.TeamFoundation.PowerTools.CheckinPolicies.ForbiddenPatterns" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/>
<bindingRedirect oldVersion="8.1.0.0-9.9.0.0" newVersion="10.0.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.TeamFoundation.PowerTools.CheckinPolicies.WorkItemQueryPolicy" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/>
<bindingRedirect oldVersion="8.1.0.0-9.9.0.0" newVersion="10.0.0.0"/>
</dependentAssembly>
但是,仍然没有运气。我遇到了同样的错误。有任何想法吗?是否有其他人获得了 TFS Power Tools checkin 策略包以与 VS 11 一起使用?您是否能够获得适用于 VS10 和 VS11 的任何 checkin 策略?
最佳答案
我们成功地将 2005 TFPT 与 VS 2005、2008、2010 一起使用。但是,开箱即用,2005 和 2008 TFPT 不适用于 VS11。但是,正如 Dave 在评论中所建议的,一些 2010 TFPT 签到政策 将使用 VS11 开箱即用。这是我通过更多实验发现的:
当我更改 TFS 中的策略配置以使用 TFPT 2010 策略时,Changeset Comments 策略开箱即用运行良好 - 无需注册表或配置文件黑客攻击。自定义路径和禁止模式策略没有。
仅供引用 - 要重新配置 TFS 以使用 TFPT 2010 策略,我只是删除了策略(从源代码控制设置对话框中),然后再次添加它们。关键是从安装了 TFPT 2010(不是 TFPT 2005 或 2008)的计算机重新添加策略。
如果您对注册表和配置文件黑客没问题,请参阅这篇文章,了解适用于所有 TFPT 2010 策略的黑客:
http://social.msdn.microsoft.com/Forums/en-US/tfsversioncontrol/thread/6bd4fe2f-b06a-49c4-a4d0-5a75d3dc3dd3/
更新:
这是我在论坛主题(上面的链接)上从 Microsoft 收到的回复:
The changeset comments policy was rolled into the product -- it's no longer part of the power tools. We've also done some additional work to make the in-box VS 2010 and VS 11 check-in policies play nicely with each other (you should be able to set them up with either client and have them work with either client). We should do this same compatibility work to the rest of the power tools check-in policies before we ship the final version. I'll file a work item to make sure this happens -- but I'm not sure it made it in for the Beta version of the VS 11 power tools. (I don't think the Beta power tools are out just yet -- but they're almost done.)
关于visual-studio - Visual Studio 11 电动工具 checkin 策略,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9535256/