# HG changeset patch # User Dirkjan Ochtman # Date 1244791486 -7200 # Node ID 021bdbf391bb429996e60497659c5db35c349c2d # Parent 6086363e8230ab616468e326a5db533b81de5939 put convert_revision in branch-closing csets diff --git a/hgsubversion/svncommands.py b/hgsubversion/svncommands.py --- a/hgsubversion/svncommands.py +++ b/hgsubversion/svncommands.py @@ -109,6 +109,10 @@ def rebuildmeta(ui, repo, hg_repo_path, uuidfile.write(uuid) uuidfile.close() + # don't reflect closed branches + if ctx.extra().get('close') and not ctx.files(): + continue + # find commitpath, write to revmap commitpath = revpath[len(subdir)+1:] if commitpath.startswith('branches'): @@ -125,7 +129,7 @@ def rebuildmeta(ui, repo, hg_repo_path, last_rev = revision # deal with branches - if ctx.extra().get('close'): # don't re-add, we just deleted! + if ctx.extra().get('close'): continue branch = ctx.branch() if branch == 'default': diff --git a/hgsubversion/svnmeta.py b/hgsubversion/svnmeta.py --- a/hgsubversion/svnmeta.py +++ b/hgsubversion/svnmeta.py @@ -454,7 +454,8 @@ class SVNMeta(object): def delbranch(self, branch, node, rev): pctx = self.repo[node] files = pctx.manifest().keys() - extra = {'close': 1} + extra = self.genextra(rev.revnum, branch) + extra['close'] = 1 if self.usebranchnames: extra['branch'] = branch or 'default' ctx = context.memctx(self.repo,