In my existing (Pre-SVN 1.5) merge strategy, we create a copy of the Trunk (called BasePoint) at the moment of branch-creation for referencing later during the merge.
When we need to merge a branch back into the trunk, we perform 2 operations.
Merge from BasePoint to LatestTrunk (Trunk has likely moved on since the original branch) into Working copy of Branch and then commit.
At this point we typically check that the merge into the branch has not damaged anything
Merge from LatestTrunk to LatestBranch back into Working copy of trunk and then commit.
Documentation suggests that I use the new reintegrate merge on the Trunk and Merge from the Branch.
Do I need to merge from the trunk into the dev branch first or is this included in the new reintegrate option?
To put it another way, does the new merge --reintegrate
functionality represent 'each of my previous merges' or 'the whole operation' ?
(FWIW I am using TortoiseSVN 1.5.1)
Merge tracking is a facility offered by some version control systems. It is the ability of a version control system to "remember" which changes have been merged from one line (branch) of development to another and act accordingly.
Sync merge is used when you want to fetch all of the latest changes made on your parent branch (e.g. trunk). Using this will keep your feature branch up-to-date with the parent branch.
The short answer is, You still have to do both steps.
The SVN book explains the process for merging as:
Notice the lack of revision numbers. This probably doesn't feel like a huge win. The new coolness is the ability to re-run the merge as you are coding in your branch, allowing you to keep the branch up to date with changes in trunk (without recording revision numbers by hand!). SVN keeps track of what needs to be merged in from trunk and what changes are unique to the branch. When you are done with the branch, --reintegrate uses that data to automatically merge only the branch changes back to trunk.
I believe reintegrate does not actually do the two operations, but instead is used to merge back into trunk from an updated branch. You will still need to do the first set of merge/commit operations to update the branch first.
Here is a link to the Subversion Book. It is possible to get this book in dead tree format.
From the link, it sounds like using --reintegrate handles some weird cases, probably like merge usually does compared to just using straight patches (read the section "Why Not Use Patches Instead?").
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With