Show More
@@ -249,11 +249,6 b' class svn_source(converter_source):' | |||||
249 | raise util.Abort(_('svn: start revision %s is not an integer') |
|
249 | raise util.Abort(_('svn: start revision %s is not an integer') | |
250 | % self.startrev) |
|
250 | % self.startrev) | |
251 |
|
251 | |||
252 | try: |
|
|||
253 | self.get_blacklist() |
|
|||
254 | except IOError: |
|
|||
255 | pass |
|
|||
256 |
|
||||
257 | self.head = self.latest(self.module, latest) |
|
252 | self.head = self.latest(self.module, latest) | |
258 | if not self.head: |
|
253 | if not self.head: | |
259 | raise util.Abort(_('no revision found in module %s') |
|
254 | raise util.Abort(_('no revision found in module %s') | |
@@ -576,26 +571,6 b' class svn_source(converter_source):' | |||||
576 | return None |
|
571 | return None | |
577 | return self.revid(dirent.created_rev, path) |
|
572 | return self.revid(dirent.created_rev, path) | |
578 |
|
573 | |||
579 | def get_blacklist(self): |
|
|||
580 | """Avoid certain revision numbers. |
|
|||
581 | It is not uncommon for two nearby revisions to cancel each other |
|
|||
582 | out, e.g. 'I copied trunk into a subdirectory of itself instead |
|
|||
583 | of making a branch'. The converted repository is significantly |
|
|||
584 | smaller if we ignore such revisions. |
|
|||
585 | """ |
|
|||
586 | self.blacklist = set() |
|
|||
587 | blacklist = self.blacklist |
|
|||
588 | for line in file("blacklist.txt", "r"): |
|
|||
589 | if not line.startswith("#"): |
|
|||
590 | try: |
|
|||
591 | svn_rev = int(line.strip()) |
|
|||
592 | blacklist.add(svn_rev) |
|
|||
593 | except ValueError: |
|
|||
594 | pass # not an integer or a comment |
|
|||
595 |
|
||||
596 | def is_blacklisted(self, svn_rev): |
|
|||
597 | return svn_rev in self.blacklist |
|
|||
598 |
|
||||
599 | def reparent(self, module): |
|
574 | def reparent(self, module): | |
600 | """Reparent the svn transport and return the previous parent.""" |
|
575 | """Reparent the svn transport and return the previous parent.""" | |
601 | if self.prevmodule == module: |
|
576 | if self.prevmodule == module: | |
@@ -809,10 +784,6 b' class svn_source(converter_source):' | |||||
809 | if revnum < self.startrev: |
|
784 | if revnum < self.startrev: | |
810 | lastonbranch = True |
|
785 | lastonbranch = True | |
811 | break |
|
786 | break | |
812 | if self.is_blacklisted(revnum): |
|
|||
813 | self.ui.note(_('skipping blacklisted revision %d\n') |
|
|||
814 | % revnum) |
|
|||
815 | continue |
|
|||
816 | if not paths: |
|
787 | if not paths: | |
817 | self.ui.debug(_('revision %d has no entries\n') % revnum) |
|
788 | self.ui.debug(_('revision %d has no entries\n') % revnum) | |
818 | continue |
|
789 | continue |
General Comments 0
You need to be logged in to leave comments.
Login now