Mercurial > hgsubversion
comparison hgsubversion/hg_delta_editor.py @ 416:cd6317fe70be
invert the svnmeta/editor relationship
author | Dirkjan Ochtman <dirkjan@ochtman.nl> |
---|---|
date | Thu, 11 Jun 2009 18:49:52 +0200 |
parents | b17b2969861c |
children | 8630d1ebcdb9 |
comparison
equal
deleted
inserted
replaced
415:b17b2969861c | 416:cd6317fe70be |
---|---|
7 from mercurial import revlog | 7 from mercurial import revlog |
8 from mercurial import node | 8 from mercurial import node |
9 from svn import delta | 9 from svn import delta |
10 from svn import core | 10 from svn import core |
11 | 11 |
12 import svnmeta | |
13 import svnexternals | 12 import svnexternals |
14 import util | 13 import util |
15 | 14 |
16 class MissingPlainTextError(Exception): | 15 class MissingPlainTextError(Exception): |
17 """Exception raised when the repo lacks a source file required for replaying | 16 """Exception raised when the repo lacks a source file required for replaying |
69 self.externals = {} | 68 self.externals = {} |
70 | 69 |
71 | 70 |
72 class HgChangeReceiver(delta.Editor): | 71 class HgChangeReceiver(delta.Editor): |
73 | 72 |
74 def __init__(self, repo, uuid=None, subdir=''): | 73 def __init__(self, meta): |
75 self.ui = repo.ui | 74 self.meta = meta |
76 self.repo = repo | 75 self.ui = meta.ui |
77 self.meta = svnmeta.SVNMeta(repo, uuid, subdir) | 76 self.repo = meta.repo |
78 self.current = RevisionData() | 77 self.current = RevisionData() |
79 | 78 |
80 def set_file(self, path, data, isexec=False, islink=False): | 79 def set_file(self, path, data, isexec=False, islink=False): |
81 if islink: | 80 if islink: |
82 data = 'link ' + data | 81 data = 'link ' + data |