Subversion 合并问题:尚无法重新集成
我正在评估 subversion 的分支/合并功能,我决定做一个简单的测试 - 我分支了一个现有项目,更改了一个文件中的注释,然后通过 Tortoise 进行了合并重新集成。
它失败了:
命令:重新集成合并https://oscar/svn/Baxtech/ViM/Branches/Test3 进入 C:\Inntec\VS2008\Baxtech\ViM
错误:无法从 'https://oscar/svn/Baxtech/ViM/Branches/Test3< 重新集成/a>' 还:
错误:一些尚未合并的修订已合并到其下
错误:进入重返社会目标; 先合并它们,然后重试。
我用谷歌搜索了一下,发现一些帖子说这与旧版本 Tortoise 中的重命名和目录更改创建的合并信息有关。
我最近确实从之前版本的 Tortoise 升级到了 1.5.5,但是这个问题似乎是 1.5 之前的问题。*... 而且我只更改了一个文件中的一些注释。 我没有进行任何重命名或目录结构更改。
话又说回来,我们已经使用主干一段时间了(没有任何分支),所以问题可能存在于那里?
因此,如果有解决办法,我将非常感谢一些帮助。 不过,这很典型吗? 这确实是一个非常简单的测试,遗憾的是现在我有点害怕使用 Subversion 进行分支。
Subversion:1.5.4(通过 VisualSVN 服务器)
Tortoise:1.5.5
我们还使用 Visual Studio 2008。
谢谢!
布莱恩
I'm evaluating subversion's branch/merge capabilities, and I decided to do a simple test - I branched an existing project, changed a comment in one file, and then did a merge reintegrate via Tortoise.
It failed:
Command: Reintegrate merge https://oscar/svn/Baxtech/ViM/Branches/Test3 into C:\Inntec\VS2008\Baxtech\ViM
Error: Cannot reintegrate from 'https://oscar/svn/Baxtech/ViM/Branches/Test3' yet:
Error: Some revisions have been merged under it that have not been merged
Error: into the reintegration target; merge them first, then retry.
I googled around for this, and I found some posts saying that this has to do with mergeinfo being created by renames and directory changes in old versions of Tortoise.
I did recently upgrade from the previous version of Tortoise to 1.5.5, however it seems like this problem was pre-1.5.*... And I only changed some comments in one file. I didn't do any renames or directory structure changes.
Then again, we've been working with the trunk for some time (without any branching), so maybe the problem exists in there?
So, if there is a fix for this I would appreciate really appreciate some help. Also, though - is this typical? This was really a very simple test, and sadly right now I'm a little scared to use Subversion for branching.
Subversion: 1.5.4 (via VisualSVN Server)
Tortoise: 1.5.5
We're also using Visual Studio 2008.
Thanks!
Brian
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(6)
我前段时间也发生过这种情况。
我不记得我到底做了什么来触发这个问题,但我可以说我也使用过 1.5 之前的版本,然后切换到 1.5.0。
Subversion 使用每个目录的 svn:mergeinfo 属性来跟踪合并。 该属性应该只出现在工作副本的根路径上(如果我错了,请纠正我)。
当我看到这个错误时,我注意到 1.5 之前的版本在工作副本内的文件上创建了显式合并信息,这导致稳定版本无法正常工作。 正如您在 最后回复中所说,删除那些额外的合并信息条目已修复对我来说也是个问题。
我的建议是尝试使用一个没有来自测试版本的提交的新存储库,并看看是否会再次发生这种情况。
This also happened to me some time ago.
I can't remember what I exactly did to trigger this problem, but I can say that I was also using a pre-1.5 release, and then switched to 1.5.0.
Subversion tracks merges using a per-directory svn:mergeinfo property. This property should only be present on the root path of the working copy (correct me if I'm wrong).
When I saw this error, I noticed that pre-1.5 versions created explicit mergeinfo on files inside the working copy, which prevented the stable release from working properly. As you say in your last reply, removing those extra mergeinfo entries fixed the problem for me too.
My suggestion is to try with a fresh repository with no commits coming from beta versions, and see if this happens again.
问题(通常)是当合并源有一些子树合并信息时,svn 1.5 会给出特定的错误消息。 正如您正确指出的那样,对此的补救措施是删除任何子树合并信息。 详细的权威答案可以在:http://blogs.collab。网/subversion/2008/07/subversion-merg/
The problem (more often than not) is when the merge source has some subtree merge info, svn 1.5 bails out giving out the specific error message. The remedy for this as you've correctly pointed out is to remove any subtree mergeinfo. A detailed authoritative answer can be found at : http://blogs.collab.net/subversion/2008/07/subversion-merg/
这个问题与MergeInfo有关。 我不太确定问题是什么,但我想我清除了 MergeInfo,现在一切都很好。
我需要更多地了解为什么我的 MergeInfo 有问题以及它实际上做了什么。 非常令人沮丧!
编辑:自从我们升级以来已经过去了一点时间,我没有再遇到这个问题。
This problem has something to do with MergeInfo. I'm not quite sure what the problem was, but I think I cleared out the MergeInfo and now everything is fine.
I need to learn a bit more about why my MergeInfo had a problem and what it actually does. Very frustrating!
EDIT: A little time has gone by since we upgraded now, and I have not encountered this problem again.
我发现从命令行合并要容易得多。
N 是您创建分支的修订版,M 是您要包含最多更改的修订版(或当前的 HEAD)。 源是分支路径。 如果您在目标工作目录中执行此操作,则不需要最后一个参数。
示例:
这会将分支中从 55 开始的所有更改合并到主干。
I've found it a lot easier to just merge from the command line.
N is the revision you made the branch, M is the revision you want to include changes up to (or HEAD for current). Source is the branch path. If you execute this inside your target working directory, you don't need the last parameter.
An example:
This will merge all changes from 55 onward in the branch to the trunk.
想不出任何原因,我从未见过这个错误,并且我大量使用分支/合并。 我要检查的几件事:
顺便说一句,您的存储库是什么版本的 SVN?
Can't think of any reasons why, I never seen this error and I use branching/merging heavily. A couple of things I would check:
BTW, what version of SVN is your repository?
我用svn很久了,从来没见过这个; 当然我没怎么用过Tortoise。 需要考虑的几点:
日志显示您尝试将
../ViM/branches/..
合并到../ViM/
中。 你没有../ViM/trunk/
或者日志只是打印出有趣的东西吗? 我想尝试将分支合并到代码库以外的其他内容中会弄乱事情。您在创建分支之后但在重新集成之前是否对主干提交了任何更改? 如果是这样,请确保在尝试将其合并回主干之前将这些更改合并到分支中。
在您的分支和主干上运行
svn cleanup
,以确保清除所有未完成的业务。我不确定这会导致任何问题,但您的主干工作副本可能需要更新才能重新集成更改。
我不确定这会导致任何问题,但
I've used svn for a long time and have never seen this; granted I haven't used Tortoise that much. A few points to consider:
The log shows you trying to merge
../ViM/branches/..
into../ViM/
. Do you you not have a../ViM/trunk/
or is the log just printing out stuff funny? I'd imagine that trying to merge a branch into something other than the code base would mess stuff up.Did you commit any changes to trunk after creating the branch but before reintegrating it? If so, make sure you merge those changes into the branch before trying to merge it back into the trunk.
Run
svn cleanup
on your branch and trunk to make sure that any unfinished business there is cleaned up.I'm not sure it would cause any issues but your working copy of trunk may need to be updated before you can reintegrate changes.