Chapter 4 of the forthcoming edition of the O’Reilly book "Version Control with Subversion" provides a good introduction to merge tracking with Subversion 1.5. It describes the common scenario of feature branches copied from a trunk, which are then kept up to date with trunk via periodic synchronization, and at the end of their lifetime are reintegrated back to trunk (with the aptly named –reintegrate option). If this model fits your merging needs, then after reading chapter 4 it is unlikely you will encounter any surprises. But what if you don’t follow this model? What if you need to do some or all of the following:
- Merge to shallow working copies?
- Merge to targets with switched subtrees?
- Merge from sources which you don’t have full access to because
of authorization restrictions, or merge to targets missing subtrees for
the same reason?
- Perform multiple merges to the same target without committing in-between?
- Merge to target, then merge to subtrees of that target?
Not to worry, in all of these cases Subversion attempts to "do the
right thing", but you may encounter seemingly unusual behavior that
doesn’t fit within the ‘synch and reintegrate’ paradigm. Key to
understanding all of these cases is a knowledge of the new
svn:mergeinfo property (frequently referred to simply as ‘mergeinfo’).
is simply the history of merges made into a path. But as with many
things that can be described so simply, mergeinfo can become a bit more
complex in practice. Initially I had brave hopes of writing a
reasonably sized blog post talking about mergeinfo; what it means and
how it works. Unfortunately as the page count of my draft post drifted
past twenty (after cutting a lot of material out) and a co-worker began
to refer to it as the "mergeinfo manifesto", we decided that it was
better suited as an article – which you can find here.
please take a look. Even if you only ever do the simplest of merges, a
quick read of the first few sections of the article and the "Parting
Thoughts" section will help you in your move to Subversion 1.5.
Read the article: Subversion 1.5 Mergeinfo.