Size: 5277
Comment: link to fastimport extension's new wiki page
|
Size: 5295
Comment: converted to 1.6 markup
|
Deletions are marked like this. | Additions are marked like this. |
Line 8: | Line 8: |
[[TableOfContents]] | <<TableOfContents>> |
Line 18: | Line 18: |
* ["Tailor"] - a generic conversion tool. | * [[Tailor]] - a generic conversion tool. |
Line 28: | Line 28: |
* ["ConvertExtension"] - the convert extension supports CVS * ["Tailor"] - a generic conversion tool * ["fromcvs"] - a fast, incremental CVS to Mercurial converter * [http://hg.beekhof.net/hg/cvs-import hg-cvs-import] - InstructionsforHgcvsimport |
* [[ConvertExtension]] - the convert extension supports CVS * [[Tailor]] - a generic conversion tool * [[fromcvs]] - a fast, incremental CVS to Mercurial converter * [[http://hg.beekhof.net/hg/cvs-import|hg-cvs-import]] - InstructionsforHgcvsimport |
Line 33: | Line 33: |
'''Note''': If ["ConvertExtension"] fails to import your repository, try using [http://cvs2svn.tigris.org/ cvs2svn] to convert first to Subversion, and then import from Subversion. The cvs2svn converter correctly handles a number of cases that the direct cvsps-based converter gets confused on. Alternatively cvs2svn can also export to git-fast-import format which FastImportExtension can process. | '''Note''': If [[ConvertExtension]] fails to import your repository, try using [[http://cvs2svn.tigris.org/|cvs2svn]] to convert first to Subversion, and then import from Subversion. The cvs2svn converter correctly handles a number of cases that the direct cvsps-based converter gets confused on. Alternatively cvs2svn can also export to git-fast-import format which FastImportExtension can process. |
Line 45: | Line 45: |
Also see ["Tailor"]. | Also see [[Tailor]]. |
Line 63: | Line 63: |
* [http://hg.rosdahl.net/yasvn2hg yasvn2hg] - yet another SVN to HG converter. Handles branches, tags and file copies/renames. Calls the svn client for each changeset, so it's not very fast. Converts whole repository only. Direct links: [http://hg.rosdahl.net/yasvn2hg/raw-file/tip/yasvn2hg yasvn2hg program], [http://hg.rosdahl.net/yasvn2hg/raw-file/tip/README README file]. * [http://dingoskidneys.com/cgi-bin/hgwebdir.cgi/queue-convert-svn/] - Patch queue against Mercurial. Patches create a convert-repo hacked to support SVN as a source. Uses the SVN API, not SVN command line + subprocess. |
* [[http://hg.rosdahl.net/yasvn2hg|yasvn2hg]] - yet another SVN to HG converter. Handles branches, tags and file copies/renames. Calls the svn client for each changeset, so it's not very fast. Converts whole repository only. Direct links: [[http://hg.rosdahl.net/yasvn2hg/raw-file/tip/yasvn2hg|yasvn2hg program]], [[http://hg.rosdahl.net/yasvn2hg/raw-file/tip/README|README file]]. * [[http://dingoskidneys.com/cgi-bin/hgwebdir.cgi/queue-convert-svn/]] - Patch queue against Mercurial. Patches create a convert-repo hacked to support SVN as a source. Uses the SVN API, not SVN command line + subprocess. |
Line 67: | Line 67: |
* [http://cheeseshop.python.org/pypi/hgsvn hgsvn] allows you to work on SVN checkouts using Mercurial (mirroring all SVN history in a local Mercurial repository on which you can also do local development). It is useful for managing private branches, submitting patches to project maintainers, have fast local operations instead of slow remote "svn up/log/blame", etc. Also useful as "one-shot" conversion tool if you just remove all the svn directories ("find . -name '.svn' |xargs rm -r") afterwards. | * [[http://cheeseshop.python.org/pypi/hgsvn|hgsvn]] allows you to work on SVN checkouts using Mercurial (mirroring all SVN history in a local Mercurial repository on which you can also do local development). It is useful for managing private branches, submitting patches to project maintainers, have fast local operations instead of slow remote "svn up/log/blame", etc. Also useful as "one-shot" conversion tool if you just remove all the svn directories ("find . -name '.svn' |xargs rm -r") afterwards. |
Line 72: | Line 72: |
[http://hg.omnifarious.org/~hopper/p4_to_hg p4_to_hg] | [[http://hg.omnifarious.org/~hopper/p4_to_hg|p4_to_hg]] |
Line 88: | Line 88: |
[http://blogs.sun.com/jglick/entry/teamware_to_mercurial_history_conversions] | [[http://blogs.sun.com/jglick/entry/teamware_to_mercurial_history_conversions]] |
Line 92: | Line 92: |
* ["SourceSafeConversion"] - A script to convert a SourceSafe project to a Mercurial Repository | * [[SourceSafeConversion]] - A script to convert a SourceSafe project to a Mercurial Repository |
Line 96: | Line 96: |
["Tailor"] is a conversion tool that can do simple conversions from a variety of systems. | [[Tailor]] is a conversion tool that can do simple conversions from a variety of systems. |
Converting Repositories
Your first option should probably be the ConvertExtension bundled with Mercurial. It supports branches, incremental imports, and a few other nice features, and is maintained by the Mercurial authors. It currently only understands CVS, subversion, Darcs and git.
Otherwise, the following tools may be useful.
Contents
1. Arch / TLA / Baz 1.5
The ConvertExtension supports GNU Arch since (df659eb23360, 0.9.5+)
Other tools for Arch conversion can be found at ArchConversion.
2. Bazaar?
Tailor - a generic conversion tool.
3. ClearCase
ClearCaseConversion - some ideas
4. CVS
Multiple convertors exist for converting from CVS to Mercurial:
ConvertExtension - the convert extension supports CVS
Tailor - a generic conversion tool
fromcvs - a fast, incremental CVS to Mercurial converter
Note: If ConvertExtension fails to import your repository, try using cvs2svn to convert first to Subversion, and then import from Subversion. The cvs2svn converter correctly handles a number of cases that the direct cvsps-based converter gets confused on. Alternatively cvs2svn can also export to git-fast-import format which FastImportExtension can process.
You can also convert from Mercurial to CVS:
CvscommitExtension - (need info)
5. Darcs
The ConvertExtension supports Darcs.
An older sample Darcs conversion script is available in the contrib/ directory of the Mercurial source.
Also see Tailor.
6. Git
See GitConversion (incremental).
7. Subversion
The ConvertExtension included in Mercurial 0.9.5 can import Subversion trees. It uses the Subversion API, so it can speak any Subversion repository access protocol.
Examples and details about Subversion interoperability can be found in WorkingWithSubversion.
Converters that work on local repositories or data (faster, if this is an option for you):
http://hg.omnifarious.org/~hopper/svn2hg - requires python2.5 and is very rough, lacking in documentation or any UI niceties at all to speak of.
Converters that work on remote repositories:
http://ajayu.memi.umss.edu.bo/viborita/weblog/svn2hg.py-convertir-repositorio-subversion-mercurial - simple script that downloads every rev info from svn server. Works on subdirectories of the repo. Handles branches, tags, etc. inefficiently (does not tell hg that they are different from any other diff). Requires pysvn, Mercurial source. Use the download link, not copy&paste.
yasvn2hg - yet another SVN to HG converter. Handles branches, tags and file copies/renames. Calls the svn client for each changeset, so it's not very fast. Converts whole repository only. Direct links: yasvn2hg program, README file.
http://dingoskidneys.com/cgi-bin/hgwebdir.cgi/queue-convert-svn/ - Patch queue against Mercurial. Patches create a convert-repo hacked to support SVN as a source. Uses the SVN API, not SVN command line + subprocess.
Syncing tools:
hgsvn allows you to work on SVN checkouts using Mercurial (mirroring all SVN history in a local Mercurial repository on which you can also do local development). It is useful for managing private branches, submitting patches to project maintainers, have fast local operations instead of slow remote "svn up/log/blame", etc. Also useful as "one-shot" conversion tool if you just remove all the svn directories ("find . -name '.svn' |xargs rm -r") afterwards.
SubversionToMercurialSync (like hgsvn, but more primitive)
8. Perforce
This utility can actually keep two repositories in sync.
Currently, it's slapped together and built to serve my particular needs, but it could probably be modified into something more general. It currently makes no attempt to do anything with Perforce's ability to track branches or the movement of changesets from branch to branch. -- EricHopper 2005-09-27 06:31:03
See also posting http://selenic.com/pipermail/mercurial/2008-July/020241.html: "Start of Mercurial git-fast-import importer (was p4 to hg)" by Paul Crowley
9. Bitkeeper
Because of the threatening behavior of Larry McVoldemort of Bitmover, no Bitkeeper conversion tools have been made publically available. See GenericConversion for details on building your own repository conversion tool.
10. TeamWare
Very experimental conversion script available if you can find nothing better:
http://blogs.sun.com/jglick/entry/teamware_to_mercurial_history_conversions
11. Visual SourceSafe
SourceSafeConversion - A script to convert a SourceSafe project to a Mercurial Repository
12. Other systems
Tailor is a conversion tool that can do simple conversions from a variety of systems. See GenericConversion for details on building your own repository conversion tool.