Show More
@@ -431,7 +431,7 b' def _wraprepo(ui, repo):' | |||
|
431 | 431 | visited.add(profile) |
|
432 | 432 | |
|
433 | 433 | try: |
|
434 |
raw = self |
|
|
434 | raw = sparse.readprofile(self, profile, rev) | |
|
435 | 435 | except error.ManifestLookupError: |
|
436 | 436 | msg = ( |
|
437 | 437 | "warning: sparse profile '%s' not found " |
@@ -455,11 +455,6 b' def _wraprepo(ui, repo):' | |||
|
455 | 455 | includes.add('.hg*') |
|
456 | 456 | return includes, excludes, profiles |
|
457 | 457 | |
|
458 | def getrawprofile(self, profile, changeid): | |
|
459 | # TODO add some kind of cache here because this incurs a manifest | |
|
460 | # resolve and can be slow. | |
|
461 | return self.filectx(profile, changeid=changeid).data() | |
|
462 | ||
|
463 | 458 | def _sparsechecksum(self, path): |
|
464 | 459 | data = self.vfs.read(path) |
|
465 | 460 | return hashlib.sha1(data).hexdigest() |
@@ -46,3 +46,10 b' def parseconfig(ui, raw):' | |||
|
46 | 46 | current.add(line) |
|
47 | 47 | |
|
48 | 48 | return includes, excludes, profiles |
|
49 | ||
|
50 | # Exists as separate function to facilitate monkeypatching. | |
|
51 | def readprofile(repo, profile, changeid): | |
|
52 | """Resolve the raw content of a sparse profile file.""" | |
|
53 | # TODO add some kind of cache here because this incurs a manifest | |
|
54 | # resolve and can be slow. | |
|
55 | return repo.filectx(profile, changeid=changeid).data() |
General Comments 0
You need to be logged in to leave comments.
Login now