Convert extension
This extension is distributed with Mercurial.
Author: several people
1. Overview
The convert extension converts repositories from other SCMs into mercurial repositories. It currently supports the following repository types:
- CVS
- Subversion
- git
It supports branches and incremental or ongoing conversion, as well as some features for tidying up new repositories, such as pruning parts of the tree and rewriting author names.
2. Configuration
Configure your .hgrc to enable the extension by adding following lines:
[extensions] hgext.convert=
3. Converting from Subversion
Subversion's python bindings are a prerequisite. The converter works best with local repositories (file://...), so you may want to use svnsync to create one if your access method is remote (especially if it is via http). The source may be a URL or a path to a repository or working directory. The converter supports a few subversion-specific options:
- svn.trunk
- Relative path to the trunk (default: "trunk")
- svn.branches
- Relative path to tree of branches (default: "branches")
Set these under [convert] in a hgrc, or on the command line as follows:
hg convert --config convert.svn.trunk=wackoname [...]
4. Converting to Mercurial
The Mercurial back end supports the following configuration options:
- hg.usebranchnames
- Use named branches to record source branches (default: True)