hg-git-fast-import
Merging, tags, closed branches, a decade of revisions — moving off Mercurial is
usually where history quietly gets lost. This converter feeds the repository
through git fast-import and keeps what was there.
What changes for you
- One repository, or many into one. Migrating a project is
single; folding a bunch of small Mercurial repositories into one Git repository ismulti. - Re-runnable. Import new revisions later without starting over —
it keeps its marks and adds only what is new (handy for a
--cronpass while both are alive). - Tags and closed branches survive, so releases and old maintenance lines still make sense in Git.
- You can check the result. The tool verifies the imported repository against the source with a diff, instead of asking you to trust it.
- Any way you install it. crates.io, release binaries or Snap.
Getting it
cargo install hg-git-fast-importhg-git-fast-import single ~/work/old-project ~/src/github.com/me/old-project
hg-git-fast-import multi --help # several hg repos into one git repo
hg-git-fast-import build-marks # rebuild the saved state if needed