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

Re: Merge From Trunk to Branch

From: Sean Laurent <sean_at_neuronfarm.com>
Date: 2004-12-14 17:25:03 CET

On Monday 13 December 2004 10:55 pm, Peter Provost wrote:
<TEXT DELETED>
> The developer has done 'svn log --stop-on-copy
> svn://svnserver/FooProject/branches/Bar'
> to figure out the repository revision of when the branch was made: 135.
> The current
> revision of the trunk is 164. The developer's working copy is fully
> committed to his
> branch.
>
> So, again, what he wants to do is to merge all changes in the trunk
> since 135 down into
> his branch without changing the trunk.

That's the key right there... he will want to merge all changes that happened
on the trunk between r135 and HEAD into his working copy of the branch.

Let's pretend he has the project checked out as:

/FooProject
        /trunk
        /branches
                /Bar

The easiest way to handle the merge, imho, is to do the following:

$ cd /FooProject/branches/Bar
$ svn merge -r135:HEAD svn://svnserver/FooProject/trunk .

Note the period at the end of the command, telling Subversion to merge these
changes into the local working copy.

The Subversion book has some good information on this:

Chapter 4. Branching and Merging
Section 4. Common Use-Cases for Merging
http://svnbook.red-bean.com/en/1.1/ch04s04.html

Sean Laurent
------------------------------
Bakers trade bread recipes on a knead-to-know basis.
------------------------------

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Tue Dec 14 17:27:18 2004

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.