Problem merging trunk into an unchanged branch in SVN
I have a SVN repository where I have the following structure:
+-trunk
| |
| +-dir1
| |
| +-dir2
|
+-branches
|
+-tags
I'm trying to make some significant changes in dir1, so I created a new branch for it, since dir2 is quite heavy and it would take a long time to check it out for every new branch I create. So I did this:
$ svn copy http://server/svn/project/trunk/dir1 http://server/svn/project/branches/branch1 -m "creating a new branch"
$ svn co http://server/svn/project/branches/branch1
No problems so far. The problem comes up whenever I try to merge the trunk int the new branch again.
$ cd branch1
$ svn merge http://server/svn/project/trunk/dir1
When I 开发者_JS百科do this, I get something like this:
C file1
C file2
[many C lines here]
Summary of conflicts:
Tree conflicts: 114
An important detail is that I'm trying to merge immediately after creating and checking out the branch, so there's no change to the branch or the trunk.
So, what am I doing wrong here? Why am I receiving all those tree conflicts?
Thanks in advance!
I ended up finding the problem.
My SVN server is < 1.5, and branch merging information is stored in the server only from 1.5.
Therefore, when I did a merge, instead of merging from the revision that the merge was created, it was merging all revisions beggining at 1, and because of that there were so many tree conflicts.
We briefly discuss how to handle merges when your repository doesn't support mergetracking in the 'Version Control with Subversion' book. See the 'Keeping a Branch in Sync Without Merge Tracking' sidebar in this section of the book (http://svnbook.red-bean.com/en/1.7/svn-book.html#svn.branchemerge.basicmerging.stayinsync)
精彩评论