Re: [IRC/patches] Failed octopus merge does not clean up

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Andreas Ericsson
Date: Wednesday, September 17, 2008 - 9:40 am

Miklos Vajna wrote:


I got it wrong (not wrt reduced heads, but still). My apologies.

If octopus (the program/strategy/whatever) continues to merge after a
branch conflicting against the currently checked out branch (let's call
it "master"), the resulting tree may not differ, but then again, it might.
OTOH, if octopus quits the merge after having encountered a conflict, the
order the branches to merge were passed will always have an impact.

Let's say you have two branches, "clean" and "conflict". Which one is
which should be obvious here.

	git merge clean conflict

will produce a tree with 'master', 'clean' and a conflicted merge of
'conflict', while

	git merge conflict clean

will produce a tree with 'master' and a conflicted merge of 'conflict'.

In short, backing out the entire merge in case of a conflict is almost
certainly the only sane thing to do. If one branch depends on another
to merge cleanly, a different approach should have been taken (depending
branch should have been rebased onto the dependent one prior to merging),
but the merge *might* succeed depending on in which order the other
branches are given as arguments. It's not a very clever idea to merge
something like that though, as bisection will invariably have to mark the
entire depending branch as BAD, although the merge itself could obviously
be a good one.

Clearly, an octopus merge should not be undertaken without knowing very
well what it is one is merging in.

-- 
Andreas Ericsson                   andreas.ericsson@op5.se
OP5 AB                             www.op5.se
Tel: +46 8-230225                  Fax: +46 8-230231
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[IRC/patches] Failed octopus merge does not clean up, Thomas Rast, (Mon Sep 15, 3:48 pm)
[PATCH] Add test that checks octopus merge cleanup, Thomas Rast, (Mon Sep 15, 3:49 pm)
Re: [IRC/patches] Failed octopus merge does not clean up, Junio C Hamano, (Mon Sep 15, 4:36 pm)
Re: [IRC/patches] Failed octopus merge does not clean up, Junio C Hamano, (Mon Sep 15, 5:20 pm)
Re: [IRC/patches] Failed octopus merge does not clean up, Jakub Narebski, (Tue Sep 16, 3:53 pm)
Re: [IRC/patches] Failed octopus merge does not clean up, Andreas Ericsson, (Tue Sep 16, 11:45 pm)
Re: [IRC/patches] Failed octopus merge does not clean up, Jakub Narebski, (Wed Sep 17, 1:11 am)
Re: [IRC/patches] Failed octopus merge does not clean up, Andreas Ericsson, (Wed Sep 17, 9:40 am)