[PATCH 5 of 8 v2] largefiles: extract 'orig' method in reposetup.status
Martin von Zweigbergk
martinvonz at gmail.com
Tue Sep 23 16:46:10 CDT 2014
# HG changeset patch
# User Martin von Zweigbergk <martinvonz at gmail.com>
# Date 1410904316 25200
# Tue Sep 16 14:51:56 2014 -0700
# Node ID a6e0710be72f0df3e84ef410b9f34d86a9990bd4
# Parent 58593ed2f24b47c7fb51be71cc854367f0a79aa8
largefiles: extract 'orig' method in reposetup.status
diff --git a/hgext/largefiles/reposetup.py b/hgext/largefiles/reposetup.py
--- a/hgext/largefiles/reposetup.py
+++ b/hgext/largefiles/reposetup.py
@@ -78,9 +78,10 @@
def status(self, node1='.', node2=None, match=None, ignored=False,
clean=False, unknown=False, listsubrepos=False):
listignored, listclean, listunknown = ignored, clean, unknown
+ orig = super(lfilesrepo, self).status
if not self.lfstatus:
- return super(lfilesrepo, self).status(node1, node2, match,
- listignored, listclean, listunknown, listsubrepos)
+ return orig(node1, node2, match, listignored, listclean,
+ listunknown, listsubrepos)
# some calls in this function rely on the old version of status
self.lfstatus = False
@@ -120,9 +121,8 @@
if match(f):
break
else:
- return super(lfilesrepo, self).status(node1, node2,
- match, listignored, listclean,
- listunknown, listsubrepos)
+ return orig(node1, node2, match, listignored, listclean,
+ listunknown, listsubrepos)
# Create a copy of match that matches standins instead
# of largefiles.
@@ -146,8 +146,8 @@
m = copy.copy(match)
m._files = tostandins(m._files)
- result = super(lfilesrepo, self).status(node1, node2, m,
- ignored, clean, unknown, listsubrepos)
+ result = orig(node1, node2, m, ignored, clean, unknown,
+ listsubrepos)
if working:
def sfindirstate(f):
More information about the Mercurial-devel
mailing list