git rebase - can hg do that ?
Giorgos Keramidas
keramida at ceid.upatras.gr
Tue May 29 14:26:19 UTC 2007
On 2007-05-29 15:56, David Jack Olrik <david at olrik.dk> wrote:
> Hi,
>
> I have been playing with gits rebase command and find it extremely
> useful, can mercurial do this ?
>
> Assume the following history exists and the current branch is "topic":
>
> A---B---C topic
> /
> D---E---F---G master
>
> From this point, the result of either of the following commands:
>
> git-rebase master
> git-rebase master topic
>
> would be:
>
> A'--B'--C' topic
> /
> D---E---F---G master
>
> The docs to 'hg transplant' says it can rebase changes, but its
> doesn't seem to do the above.
MercurialQeueus can do that, and it works nicely for local patch queues:
http://www.selenic.com/mercurial/wiki/index.cgi/MqMerge
If you have made local commits and haven't "merged" any heads,
you can even put local changesets under MQ control "after the fact",
and use the MqMerge process to rebase your local patches.
I don't know how well Git works with something like this though:
A---B---C---H---I---J ...
/ /
D---E---F---G---'
>From my limited experiments with MqMerge, it seems that MQ cannot rebase
patches *after* a merge has been done.
More information about the Mercurial
mailing list