mirror of
https://github.com/facebook/sapling.git
synced 2024-10-09 00:14:35 +03:00
convert: export revmap to source.
Sources may be able to use it to optimise their own log fetching
This commit is contained in:
parent
6209ccf2e8
commit
39cf515050
@ -216,6 +216,7 @@ class convert(object):
|
||||
|
||||
def convert(self):
|
||||
try:
|
||||
self.source.setrevmap(self.map)
|
||||
self.ui.status("scanning source...\n")
|
||||
heads = self.source.getheads()
|
||||
parents = self.walktree(heads)
|
||||
|
@ -22,6 +22,11 @@ class converter_source(object):
|
||||
self.rev = rev
|
||||
|
||||
self.encoding = 'utf-8'
|
||||
self.revmap = {}
|
||||
|
||||
def setrevmap(self, revmap):
|
||||
"""set the map of already-converted revisions"""
|
||||
self.revmap = revmap
|
||||
|
||||
def getheads(self):
|
||||
"""Return a list of this repository's heads"""
|
||||
|
Loading…
Reference in New Issue
Block a user