Patchwork D5917: annotate: respect ui.relative-paths for "binary file" message

login
register
mail settings
Submitter phabricator
Date Feb. 9, 2019, 10:17 p.m.
Message ID <2b2935d71b46e9d7df49702337e2210f@localhost.localdomain>
Download mbox | patch
Permalink /patch/38612/
State Not Applicable
Headers show

Comments

phabricator - Feb. 9, 2019, 10:17 p.m.
This revision was automatically updated to reflect the committed changes.
Closed by commit rHG446e1dcc3b5c: annotate: respect ui.relative-paths for &quot;binary file&quot; message (authored by martinvonz, committed by ).

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D5917?vs=13944&id=13965

REVISION DETAIL
  https://phab.mercurial-scm.org/D5917

AFFECTED FILES
  mercurial/commands.py

CHANGE DETAILS




To: martinvonz, #hg-reviewers, pulkit
Cc: mercurial-devel

Patch

diff --git a/mercurial/commands.py b/mercurial/commands.py
--- a/mercurial/commands.py
+++ b/mercurial/commands.py
@@ -407,12 +407,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}')