diff hgsubversion/stupid.py @ 583:a016b253910b

stupid: handle directory replacement in very stupid mode Known failures: - comprehensive/test_verify on replace_branch_with_branch: replaced files content is incorrect
author Patrick Mezard <pmezard@gmail.com>
date Tue, 02 Mar 2010 17:06:06 +0100
parents 8e025a6f0db4
children 2723152c8111
line wrap: on
line diff
--- a/hgsubversion/stupid.py
+++ b/hgsubversion/stupid.py
@@ -425,6 +425,10 @@ def fetch_branchrev(svn, meta, branch, b
                 for child, k in svn.list_files(dirpath, r.revnum):
                     if k == 'f':
                         files.append(path + '/' + child)
+                if e.action == 'R':
+                    # Check all files in replaced directory
+                    path = path + '/'
+                    files += [f for f in parentctx if f.startswith(path)]
             else:
                 if path in parentctx:
                     files.append(path)