steglig
steglig

Reputation: 1158

Getting rid of a dangling changeset after rebase in mercurial

I did a hg update --force <repo> hg pull --update --force <other repo> to get another seemingly unrelated repository into the current one.

Afterwards I merged the first changeset of the other repo (to get renamings "right").

A rebase of the other repository starting from the second changeset left the first changeset (here: revision 5431) dangling in the repository:

o  changeset:   5433:68c67c7e0bbb
|
o    changeset:   5432:331ee440893a
|\   
| |
| o  changeset:   5431:1023b4c44f18
|
o  changeset:   5430:15aff858ec36

To clean things up I'd like to get rid of revision 5431. How would I do that?

Thanks.

Upvotes: 3

Views: 609

Answers (1)

Mizipzor
Mizipzor

Reputation: 52371

By doing hg strip 5431, strip is in the mq extension.

Note that strip is a destructive operation, use with care!

Upvotes: 2

Related Questions