Ankhsvn“更新解决方案"在 VS2013 中还检索所有与 VS 项目无关的同级文件夹 [英] Ankhsvn "update solution" in VS2013 also retrieves all sibling folders not associated with the VS project

查看:18
本文介绍了Ankhsvn“更新解决方案"在 VS2013 中还检索所有与 VS 项目无关的同级文件夹的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在 Ankhsvn 中看到了一些意想不到的行为,我想知道这是否可能是一个错误,或者是设计使我误解了什么.

I'm seeing some unexpected behavior in Ankhsvn and I'm wondering if this is possibly a bug, or by design and I'm misunderstanding something.

我正在使用在线 subversion 存储库,并使用此文件结构设置了一些存储库:

I'm using an online subversion repository, and have some repositories set up with this file structure:

"Browser URL": https://www.zzzzz.com/code/mememe/subversion-2/nodes/HEAD/trunk  
"Checkout URL": https://subversion.zzzzz.com/svn/abc.MyMiscProjects/

SqlScripts1 
SqlScripts2 
SomeOtherStuff1
SomeOtherStuff2
VS2013_Solution1
VS2013_Solution2

到目前为止,我一直在使用所有这些不同的 svn 存储库文件夹和不同的本地主文件夹,没有问题(使用 TortoiseSVN).

Up until now, I had been using all of these different svn repository folders with different local home folders with no problems (using TortoiseSVN).

我也在 VisualStudio 中安装了 AnkhSVN 插件,但主要是将它与其他 SVN 存储库(在同一在线提供商处)一起使用.

I also have the AnkhSVN plugin installed in VisualStudio, but have been using it primarily with other SVN repositories (at the same online provider).

昨天在 VS2013 中,我创建了 VS2013_Solution2,当它询问我是否要将其添加到 Subversion 源代码管理时,我说是.我检查了我所有的文件,但是当我去我的家用电脑并从 Visual Studio 做了一个文件,打开 Subversion 项目",并在/VS2013_Solution2 中选择了 .sln 文件,它不仅得到了选定的解决方案,还有该存储库中的所有其他同级文件夹,即使它们与解决方案没有关联.

Yesterday from within VS2013, I created VS2013_Solution2 and when it asked if I wanted to add it to Subversion source control, I said yes. I checked in all my files, but then when I went to my home PC and from Visual Studio did a "File, Open Subversion Project", and chose the .sln file within /VS2013_Solution2, not only did it get the selected solution, but also every other sibling folder within that repository, even though they have no association with the solution.

同样,今天早上上班时,我在 VS2013 中执行了将解决方案更新到最新版本",它还将该存储库中的所有文件夹作为同级文件夹下拉到本地文件夹中的 VS2013_Solution2.

Similarly, when this morning at work I did an "Update solution to latest version" within VS2013, it also pulled all folders from that repository down as sibling folders to VS2013_Solution2 within the local folder.

现在,如果这只是 svn 作为一个整体的默认预期行为,我希望当我在 Windows 资源管理器中右键单击本地 VS2013_Solution2 文件夹并选择 TortoiseSVNSVN 更新"时会发生完全相同的事情,但在那个如果它只更新单个文件夹.

Now, if this was just the default expected behavior of svn as a whole, I would expect the exact same thing to happen when I right click my local VS2013_Solution2 folder in Windows Explorer and choose TortoiseSVN "SVN Update", but in that case it only updates the individual folder.

关于 Ankhsvn 相对于单个 SVN 存储库中所有文件的行为,我在这里是否遗漏了某些点?它是否从根本上无法像 TortoiseSVN 那样处理存储库的 subset(单个子文件夹)?

Is there some point I am missing here about the behavior of Ankhsvn with respect to all files in an individual SVN repository? Is it fundamentally incapable of dealing with a subset (individual subfolder) of a repository as TortoiseSVN seems to be able to do?

推荐答案

在进行了更多的谷歌搜索之后......
在VS2013中,File、Subversion、Change Source Control,我看到:

After doing some more googling....
In VS2013, File, Subversion, Change Source Control, I see:

Repository: https://subversion.zzzzz.com/svn/abc.MyMiscProjects/    
SCC Binding:  ^/trunk/  
SCC Binding URL: https://subversion.zzzzz.com/svn/abc.MyMiscProjects/trunk

SCC 绑定路径"旁边有一个..."按钮,显示解决方案根为:

There is a "..." button beside "SCC Binding Path" that shows the Solution Root as:

"https://subversion.zzzzz.com/svn/abc.MyMiscProjects/trunk"  
...but in the dropdown I am also able to choose:  
"https://subversion.zzzzz.com/svn/abc.MyMiscProjects/trunk/VS2013_Solution2"  

(有趣的是,其他文件夹都没有出现.)所以在我的例子中,选择直接指向我的项目文件夹的路径清除了不受欢迎的行为.

(Interestingly, none of the other folders show up.) So in my case, choosing the path pointing directly to my project folder cleared up the undesired behavior.

因此,我得出结论,Ankhsvn 的默认行为是始终假设整个存储库.虽然这显然可以被覆盖,但在我看来这不是一个好主意.

So from this, I conclude that the default behavior for Ankhsvn is to always assume the entire repository. And while this can apparently be overridden, it seems to me that it wouldn't be a good idea.

可能最实用的方法是:为每个单独的 subversion 存储库使用硬盘驱动器上的一个本地根文件夹 - 不要尝试将一个存储库中的单个文件夹微观管理到不同的本地文件夹,如果您确实需要能够要检查一个单独的文件夹,可能有一个非常具体的步骤顺序(如果在 Visual Studio 中进行,而不是例如 TortoiseSVN).

Probably the most practical approach is: use one local root folder on your hard drive for each individual subversion repository - Do not try to micro-manage individual folders in one repository to different local folders, and if you really need to be able to check out just one individual folder, there is probably a very specific order of steps to do so (if doing it from within Visual Studio, as opposed to TortoiseSVN for example).

这篇关于Ankhsvn“更新解决方案"在 VS2013 中还检索所有与 VS 项目无关的同级文件夹的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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