diff hgext/largefiles/overrides.py @ 41653:16a49c778bde

forget: pass around uipathfn and use instead of m.rel() (API) Differential Revision: https://phab.mercurial-scm.org/D5911
author Martin von Zweigbergk <martinvonz@google.com>
date Fri, 08 Feb 2019 13:08:01 -0800
parents 6a447a3d1bd0
children f164076427b2
line wrap: on
line diff
--- a/hgext/largefiles/overrides.py	Thu Feb 07 23:25:39 2019 -0800
+++ b/hgext/largefiles/overrides.py	Fri Feb 08 13:08:01 2019 -0800
@@ -1078,11 +1078,11 @@
         repo.lfstatus = False
 
 @eh.wrapfunction(cmdutil, 'forget')
-def cmdutilforget(orig, ui, repo, match, prefix, explicitonly, dryrun,
+def cmdutilforget(orig, ui, repo, match, prefix, uipathfn, explicitonly, dryrun,
                   interactive):
     normalmatcher = composenormalfilematcher(match, repo[None].manifest())
-    bad, forgot = orig(ui, repo, normalmatcher, prefix, explicitonly, dryrun,
-                       interactive)
+    bad, forgot = orig(ui, repo, normalmatcher, prefix, uipathfn, explicitonly,
+                       dryrun, interactive)
     m = composelargefilematcher(match, repo[None].manifest())
 
     try:
@@ -1098,12 +1098,12 @@
         fstandin = lfutil.standin(f)
         if fstandin not in repo.dirstate and not repo.wvfs.isdir(fstandin):
             ui.warn(_('not removing %s: file is already untracked\n')
-                    % m.rel(f))
+                    % uipathfn(f))
             bad.append(f)
 
     for f in forget:
         if ui.verbose or not m.exact(f):
-            ui.status(_('removing %s\n') % m.rel(f))
+            ui.status(_('removing %s\n') % uipathfn(f))
 
     # Need to lock because standin files are deleted then removed from the
     # repository and we could race in-between.