如何防止“解决方案的源代码控制之间似乎存在差异......"不更改 .sln 文件 [英] How to prevent "There appears to be a discrepancy between the solution's source control..." without changing the .sln file

查看:25
本文介绍了如何防止“解决方案的源代码控制之间似乎存在差异......"不更改 .sln 文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

注意:我看到了"那里似乎是解决方案的源代码管理之间的差异 ...." ,但这并不适用,因为我希望在不更改 .sln 文件的情况下修复此.>

出于某种原因,每当我打开 sln 文件中包含的解决方案时:

SccTeamFoundationServer = http://servername:8080/tfs/defaultcollectionSccAuxPath* = http://servername:8080/tfs/defaultcollection

我的 VSS 副本坚持要切换到

SccTeamFoundationServer = http://servername:8080/tfs/SccAuxPath* = http://servername:8080/tfs/

保存这些更改确实为我解决了所有问题,但是使用相同版本控制服务器的其他人在第一个版本中没有问题,但在第二个版本中不行.我希望我的计算机的版本控制服务器/路径与我同事的一致.

每个人都在使用 Visual Studio 2010 和 Visual Studio 2010 团队资源管理器.

解决方案

我在使用包含 *.vcxproj 项目文件的解决方案时遇到了这个问题,这些文件以前从 VS2008 迁移到 VS2010..sln 文件和 .vcxproj 文件中都定义了 TFS 的路径.

最简单的修复方法是更新 *.vcxproj 项目文件以使用 SAK 关键字.

即从格式更新:

$/MyProject/Directory/abc<SccAuxPath>http://servername:8080/tfs/defaultcollection</SccAuxPath><SccLocalPath>.</SccLocalPath><SccProvider>{11111111-1111-1111-1111-111111111111}</SccProvider>

SAK<SccAuxPath>SAK</SccAuxPath><SccLocalPath>SAK</SccLocalPath><SccProvider>SAK</SccProvider>

Note: I saw "There appears to be a discrepancy between the solution's source control ...." , but this doesn't apply, as I wish to fix this without changing the .sln file.

For some reason, any time I open a solution which has in the sln file:

SccTeamFoundationServer = http://servername:8080/tfs/defaultcollection
SccAuxPath* = http://servername:8080/tfs/defaultcollection

My copy of VSS insists on switching it to

SccTeamFoundationServer = http://servername:8080/tfs/
SccAuxPath* = http://servername:8080/tfs/

Saving these changes does fix everything for me, but everyone else using the same version control server is fine with the 1st version but not the second version. I wish for my computer's version control server/paths to be consistent with that of my coworkers.

Everyone is using Visual Studio 2010 with Visual Studio 2010 Team Explorer.

解决方案

I had this problem with a Solution containing *.vcxproj project files, that were previously migrated from VS2008 to VS2010. The path to TFS was defined in both the .sln file and the .vcxproj files.

The simplest fix was to update the *.vcxproj project files to use the SAK keyword.

ie update from the format:

<SccProjectName>$/MyProject/Directory/abc</SccProjectName>
<SccAuxPath>http://servername:8080/tfs/defaultcollection</SccAuxPath>
<SccLocalPath>.</SccLocalPath>
<SccProvider>{11111111-1111-1111-1111-111111111111}</SccProvider>

to

<SccProjectName>SAK</SccProjectName>
<SccAuxPath>SAK</SccAuxPath>
<SccLocalPath>SAK</SccLocalPath>
<SccProvider>SAK</SccProvider>

这篇关于如何防止“解决方案的源代码控制之间似乎存在差异......"不更改 .sln 文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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