Mercurial > hgsubversion
view __init__.py @ 16:48a44546c12f
Add a basic system for running the hgsubversion tests (although not the svnwrap ones) without requiring Nose. Nose is still the recommended way to run the tests.
Also added some tests for pushing.
author | Augie Fackler <durin42@gmail.com> |
---|---|
date | Tue, 07 Oct 2008 22:13:14 -0500 |
parents | f2636cfed115 |
children | fb1d911bb0be |
line wrap: on
line source
from mercurial import commands from mercurial import hg import svncommand import fetch_command def svn(ui, repo, subcommand, *args, **opts): return svncommand.svncmd(ui, repo, subcommand, *args, **opts) def svn_fetch(ui, svn_url, hg_repo_path=None, **opts): if not hg_repo_path: hg_repo_path = hg.defaultdest(svn_url) + "-hg" ui.status("Assuming destination %s\n" % hg_repo_path) return fetch_command.fetch_revisions(ui, svn_url, hg_repo_path, **opts) commands.norepo += " svnclone" cmdtable = { "svn": (svn, [('u', 'svn_url', '', 'Path to the Subversion server.'), ('', 'stupid', False, 'Be stupid and use diffy replay.'), ], 'hg svn subcommand'), "svnclone" :(svn_fetch, [('S', 'skipto_rev', '0', 'Skip commits before this revision.'), ('', 'stupid', False, 'Be stupid and use diffy replay.'), ('T', 'tag_locations', 'tags', 'Relative path to where tags get ' 'stored, as comma sep. values if there is more than one such path.') ], 'hg svn_fetch svn_url, dest'), }