D5917: annotate: respect ui.relative-paths for "binary file" message
martinvonz (Martin von Zweigbergk)
phabricator at mercurial-scm.org
Fri Feb 8 22:38:10 UTC 2019
martinvonz created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.
REPOSITORY
rHG Mercurial
REVISION DETAIL
https://phab.mercurial-scm.org/D5917
AFFECTED FILES
mercurial/commands.py
CHANGE DETAILS
diff --git a/mercurial/commands.py b/mercurial/commands.py
--- a/mercurial/commands.py
+++ b/mercurial/commands.py
@@ -410,12 +410,13 @@
if skiprevs:
skiprevs = scmutil.revrange(repo, skiprevs)
+ uipathfn = scmutil.getuipathfn(repo, legacyrelativevalue=True)
for abs in ctx.walk(m):
fctx = ctx[abs]
rootfm.startitem()
rootfm.data(path=abs)
if not opts.get('text') and fctx.isbinary():
- rootfm.plain(_("%s: binary file\n") % m.rel(abs))
+ rootfm.plain(_("%s: binary file\n") % uipathfn(abs))
continue
fm = rootfm.nested('lines', tmpl='{rev}: {line}')
To: martinvonz, #hg-reviewers
Cc: mercurial-devel
More information about the Mercurial-devel
mailing list