tags:

views:

30

answers:

1

I did a merge, but then I stuffed it up, so I decided to revert back. I have tried to revert to one of the revisions I merged several times, but this doesn't work. It doesn't throw any errors, it is just that my current repository state is still shown as having two heads. I also tried deleting all of the backup files that reversion automatically creates. How can I restore my repository to a clean state on one of the heads?

+1  A: 

Try hg update -C to one of the heads, or any revision.

To avoid the situation, instead of reverting you can just commit the unwanted merge, then strip it later.

Geoffrey Zheng