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

RE: Confused about how to merge changes from branch to trunk

From: Bob Archer <Bob.Archer_at_amsi.com>
Date: Wed, 25 Sep 2013 19:21:02 +0000

> Thanks for the reply.
> If i try doing merge a range of revisions FROM trunk and do not specify a
> range, it appears as though it wants to re-add every file in the project even
> though only 20ish files have changed.

How does it "appear" that way? It should only be merging stuff since your copy. It might say something about from r1 to HEAD, but it will only do what is needed.

> I select the revision range 155-158 it appears that it updated all the files that
> the other dev changed. So it looks like the first part of your suggestion worked.

You might also want to do a merge again, record only. However, I expect it won't make any changes.

> Now how do i get the changes in the branch back into trunk? Do i do a tree
> merge and select my branch as the FROM, revision 160 (thats the revision just
> after i committed the updated files from the merge FROM trunk) and the head
> revision for trunk as the TO ?

Um.. it depends on your TSVN version which you didn't indicate. You shouldn't do a tree merge... just a merge a range (1.8) or reintegration merge (1.7).

> Doing a test merge with that seems like it worked. Although it is showing one
> file as replaced from the previous dev - the other files the dev changed are
> untouched which is what i would expect since i made no changes to them.
> What was really confusing me was i thought i could do all this in a single step,
> plus not specifying a range of revisions did not seem to work for me.

Once again, it depends. If it is a feature branch, then you want to update your branch with all the trunk changes prior to re-integrating the branch. If the branch is like a release branch, then you would do a tree merge or probably a cherry pick merge to only merge stuff that happened in the branch into the trunk.

I suggest you read the chapters on Branching/Mergeing and Advanced Merging in the subversion book.

> Thanks for your help

No prob.


To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_tortoisesvn.tigris.org].
Received on 2013-09-25 21:21:09 CEST

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

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