hgext/convert/bzr.py
changeset 8126 13b36eb14324
parent 8045 e09a2f2ef85d
child 8127 17ab4dab50a6
child 8148 adce97d28389
--- a/hgext/convert/bzr.py	Thu Apr 23 08:45:44 2009 +0200
+++ b/hgext/convert/bzr.py	Thu Apr 23 15:07:05 2009 +0200
@@ -148,6 +148,11 @@
             # bazaar tracks directories, mercurial does not, so
             # we have to rename the directory contents
             if kind[1] == 'directory':
+                if kind[0] not in (None, 'directory'):
+                    # Replacing 'something' with a directory, record it
+                    # so it can be removed.
+                    changes.append((self.recode(paths[0]), revid))
+
                 if None not in paths and paths[0] != paths[1]:
                     # neither an add nor an delete - a move
                     # rename all directory contents manually