##// END OF EJS Templates
localrepo: push manifestlog and changelog construction code into store...
Augie Fackler -
r43175:3df3b139 default
parent child Browse files
Show More
@@ -28,7 +28,6 b' from . import ('
28 branchmap,
28 branchmap,
29 bundle2,
29 bundle2,
30 changegroup,
30 changegroup,
31 changelog,
32 color,
31 color,
33 context,
32 context,
34 dirstate,
33 dirstate,
@@ -41,7 +40,6 b' from . import ('
41 filelog,
40 filelog,
42 hook,
41 hook,
43 lock as lockmod,
42 lock as lockmod,
44 manifest,
45 match as matchmod,
43 match as matchmod,
46 merge as mergemod,
44 merge as mergemod,
47 mergeutil,
45 mergeutil,
@@ -1304,14 +1302,11 b' class localrepository(object):'
1304
1302
1305 @storecache('00changelog.i')
1303 @storecache('00changelog.i')
1306 def changelog(self):
1304 def changelog(self):
1307 return changelog.changelog(self.svfs,
1305 return self.store.changelog(txnutil.mayhavepending(self.root))
1308 trypending=txnutil.mayhavepending(self.root))
1309
1306
1310 @storecache('00manifest.i')
1307 @storecache('00manifest.i')
1311 def manifestlog(self):
1308 def manifestlog(self):
1312 rootstore = manifest.manifestrevlog(self.svfs)
1309 return self.store.manifestlog(self, self._storenarrowmatch)
1313 return manifest.manifestlog(self.svfs, self, rootstore,
1314 self._storenarrowmatch)
1315
1310
1316 @repofilecache('dirstate')
1311 @repofilecache('dirstate')
1317 def dirstate(self):
1312 def dirstate(self):
@@ -15,7 +15,9 b' import stat'
15
15
16 from .i18n import _
16 from .i18n import _
17 from . import (
17 from . import (
18 changelog,
18 error,
19 error,
20 manifest,
19 node,
21 node,
20 policy,
22 policy,
21 pycompat,
23 pycompat,
@@ -379,6 +381,14 b' class basicstore(object):'
379 l.sort()
381 l.sort()
380 return l
382 return l
381
383
384 def changelog(self, trypending):
385 return changelog.changelog(self.vfs, trypending=trypending)
386
387 def manifestlog(self, repo, storenarrowmatch):
388 rootstore = manifest.manifestrevlog(self.vfs)
389 return manifest.manifestlog(
390 self.vfs, repo, rootstore, storenarrowmatch)
391
382 def datafiles(self, matcher=None):
392 def datafiles(self, matcher=None):
383 return self._walk('data', True) + self._walk('meta', True)
393 return self._walk('data', True) + self._walk('meta', True)
384
394
General Comments 0
You need to be logged in to leave comments. Login now