Visual Sourcesafe,共享:提交到错误的位置
我管理一个项目。
它具有以下结构:
$/Code/MainSolution $/Code/Branches
我想在 $/Code/Branches 中分支 MainSolution
所以我这样做了,(它工作完美),我为该项目设置了一个工作文件夹并执行“获取最新”。
但是,当我在 Visual Studio 2005 中打开该解决方案时,它会将每个文件标识为新文件(文件前面的 + 号),当我提交它时,它会转到
$/Data/NameOfTheBranch
为什么会这样做?为什么它不遵守我的规则?
I have a project under my management.
It has the following structure:
$/Code/MainSolution
$/Code/Branches
I want to branch the MainSolution in $/Code/Branches
So I do it, (it works perfectly), I set a working folder for that project and do a 'get latest'.
But when I open that solution in Visual Studio 2005 it identifies every file as new (+ sign in front of the file) and when I commit it it goes to
$/Data/NameOfTheBranch
Why does it do that? Why doesn't it follow MY rules?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
我通常使解决方案下的所有 vcproj 文件具有以下内容:
这将使其从解决方案文件中获取源安全信息。确保解决方案文件是分支的,而不是在两个分支中共享。打开分支解决方案,然后转到“更改源代码管理”并将解决方案绑定到 SourceSafe 中的正确位置。
这一切都相当脆弱(或者也许我不完全理解它),但我通常只是戳它直到它起作用。
并且,像往常一样:如果可能的话,迁移到不同的源代码控制系统。必然、颠覆、善变……
I usually make all vcproj files under solution have the following:
This will make it pick up the sourcesafe information from the solution file. Make sure solution file is branched, not shared in the 2 branches. Open the branched solution and then go to "Change Source Control" and bind the solution to the correct location in SourceSafe.
This is all rather fragile (or perhaps I don't fully understand it) but I usually just poke at it until it works.
And, as usual: if at all possible migrate to a different source control system. Perforce, Subversion, Mercurial...
转到文件、源代码管理、更改
源代码管理(至少在 VS2008 上)。
查看“服务器绑定”列。
一般来说,您希望绑定到
指向解决方案的根项目
VSS 中解决方案的目录
和所有项目。如果没有,则:
取消绑定所有项目和
解决方案。
按住 Shift 键选择整个列表。
将所有内容绑定到解决方案根目录。
如果您在分支和固定项目之前执行此操作,则会更容易。之后执行此操作,您将必须对 .sln 文件进行分支,也许还对 .vcproj 和 .vspscc 进行分支,以便正确保存修改。
这里是有关 VSS 和 Visual Studio 管理的文件的一个很好的参考。这些文件很容易变得不正常。
我管理 VSS 数据库多年,最近转向 Mercurial,并且从未回头。 VSS 中的分支和合并非常糟糕。
Go to File, Source Control, Change
Source Control (at least on VS2008).
Look at the Server Binding column.
Generally you want the binding to
point to the solution's root project
directory in VSS for the solution
and all the projects. If not, then:
Unbind all the projects and the
solution.
Shift-select the entire list.
Bind everything to the solution root.
If you do this before branching and pinning the project, it will be easier. Doing it afterward you will have to branch the .sln file and perhaps the .vcproj and the .vspscc as well for the modifications to be saved correctly.
Here's a good reference for the files VSS and Visual Studio manage. These files can easily get out-of-whack.
I administered a VSS database for too many years and recently switched to Mercurial and haven't looked back. Branching and merging in VSS is horrible.