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

RE: How to switch branches without merging

From: Bob Archer <Bob.Archer_at_amsi.com>
Date: Fri, 7 Nov 2008 12:51:59 -0500

I would always say that doing a switch if you have a dirty working
directory is not a good idea. I think this is what you are asking. Doing
a switch does not do any merge at all.

So, before you switch make sure to commit or revert your current working
dir. Then do your switch to your main. Make your changes and commit. Now
you can switch back to your 1.3 branch.

If you want to get the fix you made in Main into 1.3 then you will want
to do a merge. If you are using svn 1.5 you can run a merge command and
it will merge everthing into 1.3 that you did in main since the branch
was made... or you can specify the specific changeset (revision num)
from main to merge into 1.3 branch. After you do your merge you can
commit that to your 1.3 branch.

I hope this answered what you were asking.

BOb

-----Original Message-----
From: afroblanco [mailto:jeremypollack_at_gmail.com]
Sent: Friday, November 07, 2008 12:29 PM
To: users_at_tortoisesvn.tigris.org
Subject: How to switch branches without merging

Hello all,

So, I'm wanting to start using the Branching feature of TortoiseSVN, so
that
I can keep my production code separate from my code that is still a
work-in-progress. So far, so good, right?

However, the problems arise when I want to switch from one of my
branches to
the main trunk.

Here's the hypothetical :

I'm working on a branch called MyCode_Version_1.3, which represents the
next
version of my app. The main trunk is called MyCode_Main, which
represents
code that is currently running on my production server. I'm doing some
work
on MyCode_Version_1.3, when all of a sudden one of my coworkers finds a
bug
in the Main Trunk. Bad news.

Okay, so obviously I want to switch to the main trunk, fix the bug,
check in
my code, and then go back to working on MyCode_Version_1.3. However,
I'm
not yet ready to merge MyCode_Version_1.3 into MyCode_Main. As far as I
know, the only way to prevent a merge is to check in MyCode_Version_1.3
before switching to MyCode_Main. This is a problem - the code that I'm
working on in MyCode_Version_1.3 is still a work in progress, and some
of it
hasn't even been compiled yet. I'm not yet ready for my team members,
who
are also working on MyCode_Version_1.3, to see my changes.

Is there a way that I can switch between MyCode_Version_1.3 and
MyCode_Main
without doing a merge, and without having to check in
MyCode_Version_1.3?

-- 
View this message in context:
http://www.nabble.com/How-to-switch-branches-without-merging-tp20385173p
20385173.html
Sent from the tortoisesvn - users mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe_at_tortoisesvn.tigris.org
For additional commands, e-mail: users-help_at_tortoisesvn.tigris.org
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe_at_tortoisesvn.tigris.org
For additional commands, e-mail: users-help_at_tortoisesvn.tigris.org
Received on 2008-11-07 18:52:13 CET

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.