##// END OF EJS Templates
children: define inferrepo in command decorator
Gregory Szorc -
r21780:2d3fb847 default
parent child Browse files
Show More
@@ -14,7 +14,7 b' This extension is deprecated. You should'
14 "children(REV)"` instead.
14 "children(REV)"` instead.
15 '''
15 '''
16
16
17 from mercurial import cmdutil, commands
17 from mercurial import cmdutil
18 from mercurial.commands import templateopts
18 from mercurial.commands import templateopts
19 from mercurial.i18n import _
19 from mercurial.i18n import _
20
20
@@ -26,7 +26,8 b" testedwith = 'internal'"
26 [('r', 'rev', '',
26 [('r', 'rev', '',
27 _('show children of the specified revision'), _('REV')),
27 _('show children of the specified revision'), _('REV')),
28 ] + templateopts,
28 ] + templateopts,
29 _('hg children [-r REV] [FILE]'))
29 _('hg children [-r REV] [FILE]'),
30 inferrepo=True)
30 def children(ui, repo, file_=None, **opts):
31 def children(ui, repo, file_=None, **opts):
31 """show the children of the given or working directory revision
32 """show the children of the given or working directory revision
32
33
@@ -46,5 +47,3 b' def children(ui, repo, file_=None, **opt'
46 for cctx in ctx.children():
47 for cctx in ctx.children():
47 displayer.show(cctx)
48 displayer.show(cctx)
48 displayer.close()
49 displayer.close()
49
50 commands.inferrepo += " children"
General Comments 0
You need to be logged in to leave comments. Login now