Mercurial > hg
changeset 1945:dec6d3c13dbf
new type of repo: bundle://path/to/repo+/path/to/bundlename
You can use it to pull only some changeset from an uncompressed
bundle.
author | Benoit Boissinot <benoit.boissinot@ens-lyon.org> |
---|---|
date | Mon, 13 Mar 2006 03:56:36 +0100 |
parents | fdf40c9b3306 |
children | 9fee186f7f0d |
files | mercurial/hg.py |
diffstat | 1 files changed, 9 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/hg.py Mon Mar 13 03:54:23 2006 +0100 +++ b/mercurial/hg.py Mon Mar 13 03:56:36 2006 +0100 @@ -8,7 +8,7 @@ from node import * from repo import * from demandload import * -demandload(globals(), "localrepo httprepo sshrepo statichttprepo") +demandload(globals(), "localrepo bundlerepo httprepo sshrepo statichttprepo") def repository(ui, path=None, create=0): if path: @@ -24,5 +24,13 @@ ui, path.replace("old-http://", "http://")) if path.startswith("ssh://"): return sshrepo.sshrepository(ui, path) + if path.startswith("bundle://"): + path = path[9:] + s = path.split("+", 1) + if len(s) == 1: + repopath, bundlename = "", s[0] + else: + repopath, bundlename = s + return bundlerepo.bundlerepository(ui, repopath, bundlename) return localrepo.localrepository(ui, path, create)