开发者

Using TortoiseSVN to Merge Feature Branch Prior to SVN 1.5

开发者 https://www.devze.com 2023-02-08 08:27 出处:网络
I\'m using Subversion 1.3 or 1.4. I can\'t upgrade my server to 1.5 yet. I\'ve created a branch, made changes, and now need to merge it back into the trunk since I\'ve fini开发者_JAVA百科shed working

I'm using Subversion 1.3 or 1.4. I can't upgrade my server to 1.5 yet. I've created a branch, made changes, and now need to merge it back into the trunk since I've fini开发者_JAVA百科shed working on my branch.

In the time since I branched (~one month), many changes hit the trunk. I have merged those into my branch using SVN's "merge revisions" feature. This means that the branch contains the latest trunk code, along with my changes.

I can't use the Tortoise SVN "reintegrate branch" feature, since I don't have 1.5. I tried merging the revision range of the branch into the trunk, but I get tons of conflicts (and tree conflicts). I'm not sure why, since my branch has merged all the changes from the trunk (rebased).

I did some restructuring (moving files around, creating/deleting directories). I feel like I'm missing something; if my branch has the latest trunk code plus the branch changes, why is the merge back to trunk full of conflicts?

How can I quickly/easily merge my updated branch back to the trunk?


I'm not sure why Raghuram's answer is accepted.

This describes how to merge feature branches back into trunk and retire them in version 1.4

http://svnbook.red-bean.com/en/1.4/svn-book.html#svn.branchmerge.commonuses.patterns.feature


Referring to the SVN Redbook, prior to 1.5, the way to merge changes back to trunk is to specify the revision number prior to the branch explicitly. Quoting the relevant section...

Merge a branch back into the trunk (assuming that you have a working copy of the trunk, and that the branch was created in revision 250):

$ svn merge -r 250:HEAD http://svn.red-bean.com/repos/branches/my-branch

Also, this needs to be done from the working copy of the trunk and not the branch. Perhaps this is what is causing the conflicts you have mentioned.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号