This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: git is live
- From: Tom Tromey <tromey at redhat dot com>
- To: Cary Coutant <ccoutant at google dot com>
- Cc: Pedro Alves <palves at redhat dot com>, GDB Development <gdb at sourceware dot org>, Binutils Development <binutils at sourceware dot org>
- Date: Mon, 28 Oct 2013 19:53:49 -0600
- Subject: Re: git is live
- Authentication-results: sourceware.org; auth=none
- References: <877gd5iyaz dot fsf at fleche dot redhat dot com> <CAHACq4o_Lgy7G5c9rRLB1tijmEngrOn8UgsQVdrnk9j8o1=D1A at mail dot gmail dot com> <5266CCDC dot 6090803 at redhat dot com> <CAHACq4qqw4MZznnW7zAnOMW2kHEYRRyymAphoEiY1Of5Qeks8w at mail dot gmail dot com>
Cary> I got this far with no problems (thanks!), but my old branches don't
Cary> seem to have any common commits with the new binutils-gdb/master. Are
Cary> you doing the rebase with an explicit merge-base (e.g., "git branch
Cary> new-branch binutils-gdb/master; git rebase --onto new-branch
Cary> old-master old-branch")? Or should "git rebase binutils-gdb/master
Cary> old-branch" work? (I'm hesitant to try that.)
You want git rebase --onto.
I did it using "git format-patch" followed by "git am" the first time.
The second time I did Pedro's approach and used "git rebase --onto".
Both of these worked great, though some manual labor is needed.
(Actually the second time I wrote a script to automate it: using git
merge-base to find the root of a branch and then looking up the
corresponding commit in the new tree -- but for reasons I don't know it
only worked for about half of my branches.)
Tom