Replay old history to fix renames.

1. Status

This extension is not distributed with Mercurial.

Author: MartinGeisler


2. Overview

Mercurial relies on an accurate record of renames in order to do merges properly. If files have been moved around without the knowledge of Mercurial, then rename information may be missing. This extension let you redo changesets with hg addremove being run before each commit, it basically does

$ hg update N
$ hg revert --all --rev N+1
$ hg addremove
$ hg commit

in a loop over a range of revisions you specify. The new changesets are identical to the old changesets, with the exception of the added rename information.

By default, the original history is left in place, but the old heads are closed. You can also strip away the old history or have the extension merge the old heads into the new heads.

3. Configuration

Configure your .hgrc to enable the extension by adding following lines:

fixrenames = ~/path/to/

4. Sponsorship

The work on this extension was sponsored by the University of Zurich, Switzerland.


FixrenamesExtension (last edited 2012-11-04 02:29:05 by mpm)