git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Rebasing multiple branches
@ 2010-12-21 13:40 Leonid Podolny
  2010-12-21 14:06 ` Johannes Sixt
  0 siblings, 1 reply; 6+ messages in thread
From: Leonid Podolny @ 2010-12-21 13:40 UTC (permalink / raw)
  To: git

Hi,
I need to rebase a rather complicated formation of branches.

My situation is like this (I hope ASCII graphics survive the sending):

         B--o--o--o--o--o--o  <--branch A
        /                   \
o--o--A--o--E  <--master    C--o--o--o--D  <--branch C
        \                   /
         C--o--o--o--o--o--o  <--branch B

I would like to rebase all three branches A, B and C onto commit E, and 
it's very important to keep the information about merges. For instance, 
if I take commit C and rebase it onto D, it serializes all the 
intermediate commits.
The only solution I managed to come up with is as follows:
- Take branch A and rebase it onto D (branch A').
- Same with branch B.
- Open a new branch C' from commit E.
- Merge A' and B' into C'.
- Manually cherry-pick all commits from commit C to commit D into branch C'.


The last step is way too ugly to be the only possible solution :)

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2010-12-31 14:55 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-12-21 13:40 Rebasing multiple branches Leonid Podolny
2010-12-21 14:06 ` Johannes Sixt
2010-12-22 14:36   ` Enrico Weigelt
2010-12-22 14:54     ` Leonid Podolny
2010-12-30  5:35       ` Enrico Weigelt
2010-12-31 14:55         ` Thomas Rast

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).