Mercurial > public > mercurial-scm > hg-stable
diff mercurial/cmdutil.py @ 36991:317382151ac3
templater: rename .render(mapping) to .renderdefault(mapping) (API)
I'm going to add templ.render(t, mapping) and templ.generate(t, mapping) in
place of stringify(templ(t, **mapping)) and templ(t, **mapping) respectively.
.. api::
The ``render(mapping)`` method of the templater has been renamed to
``renderdefault(mapping)``.
author | Yuya Nishihara <yuya@tcha.org> |
---|---|
date | Sat, 17 Mar 2018 11:23:04 +0900 |
parents | afac8ab37c2c |
children | f0b6fbea00cf |
line wrap: on
line diff
--- a/mercurial/cmdutil.py Sat Mar 17 15:22:14 2018 +0900 +++ b/mercurial/cmdutil.py Sat Mar 17 11:23:04 2018 +0900 @@ -907,7 +907,7 @@ mapping = {'ctx': ctx, 'revcache': {}} if props: mapping.update(props) - return t.render(mapping) + return t.renderdefault(mapping) def _buildfntemplate(pat, total=None, seqno=None, revwidth=None, pathname=None): r"""Convert old-style filename format string to template string