Mercurial > public > mercurial-scm > hg
diff mercurial/commands.py @ 26639:92d67e5729b9
exchange: move bundle specification parsing from cmdutil
Clone bundles require a well-defined string to specify the type of
bundle that is listed so clients can filter compatible file types. The
`hg bundle` command and cmdutil.parsebundletype() already establish the
beginnings of a bundle specification format.
As part of formalizing this format specification so it can be used by
clone bundles, we move the specification parsing bits verbatim to
exchange.py, which is a more suitable place than cmdutil.py. A
subsequent patch will refactor this code to make it more appropriate as
a general API.
author | Gregory Szorc <gregory.szorc@gmail.com> |
---|---|
date | Tue, 13 Oct 2015 11:43:21 -0700 |
parents | ae5f7be2b4ab |
children | b13fdcc4e700 |
line wrap: on
line diff
--- a/mercurial/commands.py Tue Mar 24 00:28:28 2015 +0900 +++ b/mercurial/commands.py Tue Oct 13 11:43:21 2015 -0700 @@ -1242,7 +1242,7 @@ revs = scmutil.revrange(repo, opts['rev']) bundletype = opts.get('type', 'bzip2').lower() - cgversion, bcompression = cmdutil.parsebundletype(repo, bundletype) + cgversion, bcompression = exchange.parsebundlespec(repo, bundletype) if opts.get('all'): base = ['null']