diff mercurial/debugcommands.py @ 31216:21fa3d3688f3

vfs: replace 'scmutil.opener' usage with 'scmutil.vfs' The 'vfs' class is the first class citizen for years. We remove all usages of the older API. This will let us remove the old API eventually.
author Pierre-Yves David <pierre-yves.david@ens-lyon.org>
date Thu, 02 Mar 2017 03:52:36 +0100
parents 8fc55bbd2235
children 9cdba6072b97
line wrap: on
line diff
--- a/mercurial/debugcommands.py	Tue Mar 07 12:52:00 2017 -0800
+++ b/mercurial/debugcommands.py	Thu Mar 02 03:52:36 2017 +0100
@@ -76,7 +76,7 @@
     """find the ancestor revision of two revisions in a given index"""
     if len(args) == 3:
         index, rev1, rev2 = args
-        r = revlog.revlog(scmutil.opener(pycompat.getcwd(), audit=False), index)
+        r = revlog.revlog(scmutil.vfs(pycompat.getcwd(), audit=False), index)
         lookup = r.lookup
     elif len(args) == 2:
         if not repo:
@@ -452,7 +452,7 @@
     spaces = opts.get('spaces')
     dots = opts.get('dots')
     if file_:
-        rlog = revlog.revlog(scmutil.opener(pycompat.getcwd(), audit=False),
+        rlog = revlog.revlog(scmutil.vfs(pycompat.getcwd(), audit=False),
                              file_)
         revs = set((int(r) for r in revs))
         def events():