Mercurial > hg
diff mercurial/templatekw.py @ 39367:83f8f7b9fa60
templatekw: alias {file} of files list to {path}
This is a part of the name unification. All {path}s will be changed to
repository-absolute (i.e. canonical) paths.
https://www.mercurial-scm.org/wiki/GenericTemplatingPlan#Dictionary
author | Yuya Nishihara <yuya@tcha.org> |
---|---|
date | Sun, 05 Aug 2018 16:14:18 +0900 |
parents | 390287321b4b |
children | 5b1d406b39f1 |
line wrap: on
line diff
--- a/mercurial/templatekw.py Wed Aug 29 18:52:09 2018 +0300 +++ b/mercurial/templatekw.py Sun Aug 05 16:14:18 2018 +0900 @@ -297,7 +297,7 @@ if 'files' not in revcache: revcache['files'] = ctx.p1().status(ctx)[:3] files = revcache['files'][index] - return compatlist(context, mapping, name, files, element='file') + return templateutil.compatfileslist(context, mapping, name, files) @templatekeyword('file_adds', requires={'ctx', 'revcache'}) def showfileadds(context, mapping): @@ -359,7 +359,7 @@ changeset. """ ctx = context.resource(mapping, 'ctx') - return compatlist(context, mapping, 'file', ctx.files()) + return templateutil.compatfileslist(context, mapping, 'file', ctx.files()) @templatekeyword('graphnode', requires={'repo', 'ctx'}) def showgraphnode(context, mapping):