comparison contrib/synthrepo.py @ 32337:46ba2cdda476

registrar: move cmdutil.command to registrar module (API) cmdutil.command wasn't a member of the registrar framework only for a historical reason. Let's make that happen. This patch keeps cmdutil.command as an alias for extension compatibility.
author Yuya Nishihara <yuya@tcha.org>
date Sat, 09 Jan 2016 23:07:20 +0900
parents bd872f64a8ba
children ba479850c9c7
comparison
equal deleted inserted replaced
32336:ff874d34c856 32337:46ba2cdda476
51 nullid, 51 nullid,
52 nullrev, 52 nullrev,
53 short, 53 short,
54 ) 54 )
55 from mercurial import ( 55 from mercurial import (
56 cmdutil,
57 context, 56 context,
58 error, 57 error,
59 hg, 58 hg,
60 patch, 59 patch,
60 registrar,
61 scmutil, 61 scmutil,
62 util, 62 util,
63 ) 63 )
64 64
65 # Note for extension authors: ONLY specify testedwith = 'ships-with-hg-core' for 65 # Note for extension authors: ONLY specify testedwith = 'ships-with-hg-core' for
67 # be specifying the version(s) of Mercurial they are tested with, or 67 # be specifying the version(s) of Mercurial they are tested with, or
68 # leave the attribute unspecified. 68 # leave the attribute unspecified.
69 testedwith = 'ships-with-hg-core' 69 testedwith = 'ships-with-hg-core'
70 70
71 cmdtable = {} 71 cmdtable = {}
72 command = cmdutil.command(cmdtable) 72 command = registrar.command(cmdtable)
73 73
74 newfile = {'new fi', 'rename', 'copy f', 'copy t'} 74 newfile = {'new fi', 'rename', 'copy f', 'copy t'}
75 75
76 def zerodict(): 76 def zerodict():
77 return collections.defaultdict(lambda: 0) 77 return collections.defaultdict(lambda: 0)