comparison mercurial/exthelper.py @ 41059:41cd64a81dd9

exthelper: drop a compatibility shim with '^command' syntax This syntax was dropped in fa88170c10bb.
author Matt Harbison <matt_harbison@yahoo.com>
date Thu, 27 Dec 2018 00:10:40 -0500
parents 021496277392
children f7863606d4ff
comparison
equal deleted inserted replaced
41058:55e8da487b8a 41059:41cd64a81dd9
35 self._extcommandwrappers = [] 35 self._extcommandwrappers = []
36 self._functionwrappers = [] 36 self._functionwrappers = []
37 self._duckpunchers = [] 37 self._duckpunchers = []
38 self.cmdtable = {} 38 self.cmdtable = {}
39 self.command = registrar.command(self.cmdtable) 39 self.command = registrar.command(self.cmdtable)
40 if '^init' in commands.table:
41 olddoregister = self.command._doregister
42
43 def _newdoregister(self, name, *args, **kwargs):
44 if kwargs.pop('helpbasic', False):
45 name = '^' + name
46 return olddoregister(self, name, *args, **kwargs)
47 self.command._doregister = _newdoregister
48
49 self.configtable = {} 40 self.configtable = {}
50 self.configitem = registrar.configitem(self.configtable) 41 self.configitem = registrar.configitem(self.configtable)
51 42
52 def merge(self, other): 43 def merge(self, other):
53 self._uicallables.extend(other._uicallables) 44 self._uicallables.extend(other._uicallables)