1

I'm trying reintegrate branch to trunk, but when i click "Test merge" in the TortoiseSVN, I get this message:

Command: Reintegrate merge https://127.0.0.1/svn/global/branches/somebranch into D:\wwwroot\work 
Error: Reintegrate can only be used if revisions 8459 through 11952 were previously  
Error:  merged from https://127.0.0.1/svn/global/trunk to the reintegrate  
Error:  source, but this is not the case:  
Error:    
Error:  branches/somebranch/file.js  
Error:   
Error:     Missing ranges:  
Error:  /trunk/file.js:11059,11212,11392,11486,11719,11732-11733  
Completed!

However, the file in the branch and in trunk exactly the same. This file was in the somebranch when i merge trunk to my branch.

Anyone encountered this problem?

  • Would http://stackoverflow.com/questions/2472249/problem-reintegrating-a-branch-into-the-trunk-in-subversion-1-5 help? – VonC Apr 25 '12 at 07:10

2 Answers2

1

I'm not an expert with SVN, but I think your answer is in: http://tortoisesvn.net/docs/release/TortoiseSVN_en/tsvn-dug-merge.html#tsvn-dug-merge-maintenance and http://svnbook.red-bean.com/en/1.7/svn.branchmerge.basicmerging.html#svn.branchemerge.basicmerging.stayinsync

In short: regardless of what your actual changes might be, you need to keep your branch in sync with trunk so that the reintegrate knows exactly what has and hasn't changed.

If you're only making changes in the branch and none in trunk, this is a non-issue. But once you've made a change or two in trunk, the branch needs to include those.

DaveD
  • 2,196
  • 1
  • 23
  • 33
1

If you are working on a branch and have been keeping it up to date with others work you might be bemused when you create a working copy of the trunk and attempt to reintegrate your branch if you get a message something like this:

~/python/orb2 $ svn merge --reintegrate https://paulwhippconsulting.slsapp.com/source/orb/branches/bronze_services
svn: Reintegrate can only be used if revisions 650 through 694 were previously merged from https://paulwhippconsulting.slsapp.com/source/orb/trunk to the reintegrate source, but this is not the case:
  branches/bronze_services/occl
    Missing ranges: /trunk/occl:650-693

I've seen a number of workarounds on Google but they made me nervous as 'hacks'. To address it I decided to do just what subversion is hinting at in the message. I went back to my branch and explicitly merged the specified revisions:

~/python/orb $ svn merge -r 650:693 https://paulwhippconsulting.slsapp.com/source/orb/trunk
~/python/orb $ svn commit -m 'merged revisions 650:693 from trunk'
Sending        occl

Committed revision 695. Once I did this, I was able to return to the working copy of trunk and reintegrate the branch without any problems.

I hope this helps

Paul Whipp
  • 16,028
  • 4
  • 42
  • 54