# HG changeset patch # User Yuya Nishihara # Date 2015-04-03 12:36:39 # Node ID d80819f67d5961a91da723e29677c78f8992b789 # Parent ea24cf92557a5a30c4d8d8f8555ad57003afb02a templater: tell hggettext to collect help of template functions diff --git a/Makefile b/Makefile --- a/Makefile +++ b/Makefile @@ -118,6 +118,7 @@ i18n/hg.pot: $(PYFILES) $(DOCFILES) i18n hgext/*.py hgext/*/__init__.py \ mercurial/fileset.py mercurial/revset.py \ mercurial/templatefilters.py mercurial/templatekw.py \ + mercurial/templater.py \ mercurial/filemerge.py \ $(DOCFILES) > i18n/hg.pot.tmp # All strings marked for translation in Mercurial contain diff --git a/mercurial/templater.py b/mercurial/templater.py --- a/mercurial/templater.py +++ b/mercurial/templater.py @@ -793,3 +793,6 @@ def stylemap(styles, paths=None): return style, mapfile raise RuntimeError("No hgweb templates found in %r" % paths) + +# tell hggettext to extract docstrings from these functions: +i18nfunctions = funcs.values()