Skip to content
Snippets Groups Projects
Commit 3447c088 authored by Patrick Mezard's avatar Patrick Mezard
Browse files

convert: cleanup svn file copy handling

parent a6e2e60b
No related merge requests found
......@@ -552,16 +552,4 @@
kind = svn.ra.check_path(self.ra, entrypath, revnum)
if kind == svn.core.svn_node_file:
if ent.copyfrom_path:
copyfrom_path = self.getrelpath(ent.copyfrom_path)
if copyfrom_path:
self.ui.debug("Copied to %s from %s@%s\n" %
(entrypath, copyfrom_path,
ent.copyfrom_rev))
# It's probably important for hg that the source
# exists in the revision's parent, not just the
# ent.copyfrom_rev
fromkind = svn.ra.check_path(self.ra, copyfrom_path, ent.copyfrom_rev)
if fromkind != 0:
copies[self.recode(entry)] = self.recode(copyfrom_path)
entries.append(self.recode(entry))
......@@ -567,4 +555,18 @@
entries.append(self.recode(entry))
if not ent.copyfrom_path:
continue
copyfrom_path = self.getrelpath(ent.copyfrom_path)
if not copyfrom_path:
continue
self.ui.debug("copied to %s from %s@%s\n" %
(entrypath, copyfrom_path, ent.copyfrom_rev))
# It's probably important for hg that the source
# exists in the revision's parent, not just the
# ent.copyfrom_rev
fromkind = svn.ra.check_path(self.ra, copyfrom_path, ent.copyfrom_rev)
if fromkind != 0:
copies[self.recode(entry)] = self.recode(copyfrom_path)
elif kind == 0: # gone, but had better be a deleted *file*
self.ui.debug("gone from %s\n" % ent.copyfrom_rev)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment