Show More
@@ -10,7 +10,7 b'' | |||||
10 | import copy |
|
10 | import copy | |
11 | import os |
|
11 | import os | |
12 |
|
12 | |||
13 |
from mercurial import error |
|
13 | from mercurial import error, match as match_, util | |
14 | from mercurial.i18n import _ |
|
14 | from mercurial.i18n import _ | |
15 | from mercurial import scmutil, localrepo |
|
15 | from mercurial import scmutil, localrepo | |
16 |
|
16 | |||
@@ -38,17 +38,17 b' def reposetup(ui, repo):' | |||||
38 | def __getitem__(self, changeid): |
|
38 | def __getitem__(self, changeid): | |
39 | ctx = super(lfilesrepo, self).__getitem__(changeid) |
|
39 | ctx = super(lfilesrepo, self).__getitem__(changeid) | |
40 | if self.lfstatus: |
|
40 | if self.lfstatus: | |
41 | class lfilesmanifestdict(manifest.manifestdict): |
|
|||
42 | def __contains__(self, filename): |
|
|||
43 | orig = super(lfilesmanifestdict, self).__contains__ |
|
|||
44 | return orig(filename) or orig(lfutil.standin(filename)) |
|
|||
45 | class lfilesctx(ctx.__class__): |
|
41 | class lfilesctx(ctx.__class__): | |
46 | def files(self): |
|
42 | def files(self): | |
47 | filenames = super(lfilesctx, self).files() |
|
43 | filenames = super(lfilesctx, self).files() | |
48 | return [lfutil.splitstandin(f) or f for f in filenames] |
|
44 | return [lfutil.splitstandin(f) or f for f in filenames] | |
49 | def manifest(self): |
|
45 | def manifest(self): | |
50 | man1 = super(lfilesctx, self).manifest() |
|
46 | man1 = super(lfilesctx, self).manifest() | |
51 |
|
|
47 | orig = man1.__contains__ | |
|
48 | def __contains__(self, filename): | |||
|
49 | return (orig(filename) or | |||
|
50 | orig(lfutil.standin(filename))) | |||
|
51 | man1.__contains__ = __contains__.__get__(man1) | |||
52 | return man1 |
|
52 | return man1 | |
53 | def filectx(self, path, fileid=None, filelog=None): |
|
53 | def filectx(self, path, fileid=None, filelog=None): | |
54 | orig = super(lfilesctx, self).filectx |
|
54 | orig = super(lfilesctx, self).filectx |
General Comments 0
You need to be logged in to leave comments.
Login now