Mercurial > public > mercurial-scm > hg-stable
diff mercurial/commands.py @ 39640:713085b45810
formatter: replace contexthint() with demand loading of ctx object
And pass in repo instead to resolve ctx from (repo, node) pair.
author | Yuya Nishihara <yuya@tcha.org> |
---|---|
date | Sat, 01 Sep 2018 15:52:18 +0900 |
parents | 4c807ec07888 |
children | 10c5eacd793f |
line wrap: on
line diff
--- a/mercurial/commands.py Thu Jun 07 21:48:11 2018 +0900 +++ b/mercurial/commands.py Sat Sep 01 15:52:18 2018 +0900 @@ -5639,7 +5639,6 @@ opts = pycompat.byteskwargs(opts) ui.pager('tags') fm = ui.formatter('tags', opts) - contexthint = fm.contexthint('tag rev node type') hexfunc = fm.hexfunc tagtype = "" @@ -5652,8 +5651,7 @@ tagtype = 'local' fm.startitem() - if 'ctx' in contexthint: - fm.context(ctx=repo[n]) + fm.context(repo=repo) fm.write('tag', '%s', t, label=label) fmt = " " * (30 - encoding.colwidth(t)) + ' %5d:%s' fm.condwrite(not ui.quiet, 'rev node', fmt,