[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Branching / Merging Help

From: Hari Kodungallur <hkodungallur_at_gmail.com>
Date: 2007-05-22 21:30:52 CEST

On 5/22/07, Neil Sheth <nsheth@gmail.com> wrote:
> Hello,
> I am relatively new to svn, and am trying to figure out the branching
> and merging process. Looking at the documentation, I see 2 main
> examples:
> From http://svnbook.red-bean.com/en/1.0/ch04s03.html, we see how to
> get updates from the trunk into your branch. Using their example,
> "svn merge -r 343:344 http://svn.example.com/repos/calc/trunk" gets
> the changes from trunk into my-calc-branch.
> From http://svnbook.red-bean.com/en/1.0/ch04s04.html, we see how to
> merge the branch back into trunk. Using their example, "svn merge -r
> 341:HEAD http://svn.example.com/repos/calc/branches/my-calc-branch"
> brings the changes from my-calc-branch into a working copy of trunk.
> The second example assumes that we haven't pulled any trunk updates
> into the branch in the course of working on the branch. The -r
> 341:HEAD part says, give me all the changes in this branch since I
> copied it. What if I had periodically pulled changes from trunk via
> the first example? In this case, if I merged back into trunk, won't I
> duplicate changes? The changes will already be in the latest trunk
> revision, and then I'll have them repeated in the branch diff?
> In the case that we are developing in a branch for some time, I will
> want to keep it updated with changes from trunk. What is the best way
> to merge this type of branch back into trunk when finished?

Periodic merges is not something that is supported by subversion currently.
I believe 1.5 or 1.6 will have it. Until then, you will have to use some
tool like svnmerge.py to keep track of it. This script is in
contrib/client-side directory of the source distribution.

-Hari Kodungallur
Received on Tue May 22 21:31:14 2007

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.