D5087: help: displaying documented aliases by default
yuja (Yuya Nishihara)
phabricator at mercurial-scm.org
Tue Oct 23 07:35:10 EDT 2018
yuja added a comment.
Queued the series for 4.9, many thanks.
> @@ -523,16 +538,20 @@
>
> f = fs[0]
> syns[f] = ', '.join(fs)
> func = e[0]
>
> + alias = getattr(func, 'alias', False)
Removed unused variable `alias`.
> @@ -554,11 +557,14 @@
>
> 1. drop prefix in old-style help lines so hg shows the alias self.help = self.help[4 + len(cmd):]
>
> + self.owndoc = 'doc' in cfg doc = cfg.get('doc', pycompat.getdoc(fn)) if doc is not None: doc = pycompat.sysstr(doc) self.__doc__ = doc
>
> + self.helpcategory = cfg.get('category', registrar.command.CATEGORY_NONE)
Maybe the default can be derived from the aliased command?
REPOSITORY
rHG Mercurial
REVISION DETAIL
https://phab.mercurial-scm.org/D5087
To: rdamazio, #hg-reviewers, durin42, yuja
Cc: yuja, mercurial-devel
More information about the Mercurial-devel
mailing list