diff mercurial/commands.py @ 41757:980e05204ed8

subrepo: use root-repo-relative path from `hg files` with ui.relative-paths=no The fix is to pass in a "subuipathfn" as we do everywhere else. Differential Revision: https://phab.mercurial-scm.org/D5978
author Martin von Zweigbergk <martinvonz@google.com>
date Sun, 17 Feb 2019 09:12:30 -0800
parents 8ab42ccb68fe
children aaad36b88298
line wrap: on
line diff
--- a/mercurial/commands.py	Sun Feb 17 09:05:28 2019 -0800
+++ b/mercurial/commands.py	Sun Feb 17 09:12:30 2019 -0800
@@ -2213,8 +2213,10 @@
 
     m = scmutil.match(ctx, pats, opts)
     ui.pager('files')
+    uipathfn = scmutil.getuipathfn(ctx.repo(), legacyrelativevalue=True)
     with ui.formatter('files', opts) as fm:
-        return cmdutil.files(ui, ctx, m, fm, fmt, opts.get('subrepos'))
+        return cmdutil.files(ui, ctx, m, uipathfn, fm, fmt,
+                             opts.get('subrepos'))
 
 @command(
     'forget',