##// END OF EJS Templates
mq: extend support for the --mq argument to extension commands...
Dan Villiom Podlaski Christiansen -
r12036:31f02288 default
parent child Browse files
Show More
@@ -2928,13 +2928,21 b' def uisetup(ui):'
2928 entry = extensions.wrapcommand(commands.table, 'init', mqinit)
2928 entry = extensions.wrapcommand(commands.table, 'init', mqinit)
2929 entry[1].extend(mqopt)
2929 entry[1].extend(mqopt)
2930
2930
2931 norepo = commands.norepo.split(" ")
2931 nowrap = set(commands.norepo.split(" ") + ['qrecord'])
2932 for cmd in commands.table.keys():
2932
2933 cmd = cmdutil.parsealiases(cmd)[0]
2933 def dotable(cmdtable):
2934 if cmd in norepo:
2934 for cmd in cmdtable.keys():
2935 continue
2935 cmd = cmdutil.parsealiases(cmd)[0]
2936 entry = extensions.wrapcommand(commands.table, cmd, mqcommand)
2936 if cmd in nowrap:
2937 entry[1].extend(mqopt)
2937 continue
2938 entry = extensions.wrapcommand(cmdtable, cmd, mqcommand)
2939 entry[1].extend(mqopt)
2940
2941 dotable(commands.table)
2942
2943 for extname, extmodule in extensions.extensions():
2944 if extmodule.__file__ != __file__:
2945 dotable(getattr(extmodule, 'cmdtable', {}))
2938
2946
2939 seriesopts = [('s', 'summary', None, _('print first line of patch header'))]
2947 seriesopts = [('s', 'summary', None, _('print first line of patch header'))]
2940
2948
@@ -170,6 +170,10 b" qinit -c shouldn't touch these files if "
170 A
170 A
171 B
171 B
172
172
173 add an untracked file
174
175 $ echo >> .hg/patches/flaf
176
173 status --mq with color (issue2096)
177 status --mq with color (issue2096)
174
178
175 $ hg status --mq --config extensions.color= --color=always
179 $ hg status --mq --config extensions.color= --color=always
@@ -177,9 +181,15 b' status --mq with color (issue2096)'
177 A A
181 A A
178 A B
182 A B
179 A series
183 A series
184 ? flaf
185
186 try the --mq option on a command provided by an extension
187
188 $ hg purge --mq --verbose --config extensions.purge=
189 Removing file flaf
190
180 $ cd ..
191 $ cd ..
181
192
182
183 init --mq without repo
193 init --mq without repo
184
194
185 $ mkdir f
195 $ mkdir f
General Comments 0
You need to be logged in to leave comments. Login now