0

With svn respo, I created a branch A (revision r0) working with my parter John. I made some changes revision r1, John committed some changes revision r2. Then I find I don’t have enough time for testing r1 changes, so I rollback which –c –r1 . John merged branch A to trunk, and mv A to branch_bak from branch. Now I create new branch B after John merge trunk, I want to merge the r1 changes on the branch A to branch B, how can I do it?

 1. I : svn commit “for point A”  revision:r1
 2. John: svn commit “for point B” revision: r2
 3. I : svn merge –c –r1 http://corp/branch/branchA revision:r3
 4. John: svn merge http://corp/branch/branchA to trunk 
 5. John:svn mv http://corp/branch/branchA http://corp/branch_bak/branchA
 6. I : svn cp trunk http://corp/branch/branchB
 7. I: I want to merge the changes on revision r1 branch A to branch B
Yannick Blondeau
  • 9,465
  • 8
  • 52
  • 74
  • 1
    I don't understand what is `svn merge -c -r1` command and how you reverted changes with it. This options are for 'cherry-pick' merges, i.e. for merging specific commits, where `-c` accepts single revision numbers and `-r` accepts revision ranges. To merge revision 1 you simply need to call `svn merge -c1 `, but I really want to know, what you did with that third line of your log – Anton Guryanov Sep 27 '12 at 12:25

1 Answers1

0

I think something like this should work:

$ cd myWorkingCopyOfBranchB
$ svn merge -c -r1 http://corp/branch/branchA@r1

You can find more info in the 'Advanced Merging' section of the SVN book.

Yannick Blondeau
  • 9,465
  • 8
  • 52
  • 74