Mercurial > hgsubversion
comparison hg_delta_editor.py @ 232:c0063328587f
Fix and test for directory deletes during branch creation.
author | Augie Fackler <durin42@gmail.com> |
---|---|
date | Tue, 07 Apr 2009 17:38:13 -0500 |
parents | f71af18c4379 |
children | c90cfa665b81 |
comparison
equal
deleted
inserted
replaced
231:b1543f243910 | 232:c0063328587f |
---|---|
843 if br_path != '': | 843 if br_path != '': |
844 br_path2 = br_path + '/' | 844 br_path2 = br_path + '/' |
845 # assuming it is a directory | 845 # assuming it is a directory |
846 self.externals[path] = None | 846 self.externals[path] = None |
847 map(self.delete_file, [pat for pat in self.current_files.iterkeys() | 847 map(self.delete_file, [pat for pat in self.current_files.iterkeys() |
848 if pat.startswith(path)]) | 848 if pat.startswith(path+'/')]) |
849 for f in ctx.walk(our_util.PrefixMatch(br_path2)): | 849 for f in ctx.walk(our_util.PrefixMatch(br_path2)): |
850 f_p = '%s/%s' % (path, f[len(br_path2):]) | 850 f_p = '%s/%s' % (path, f[len(br_path2):]) |
851 if f_p not in self.current_files: | 851 if f_p not in self.current_files: |
852 self.delete_file(f_p) | 852 self.delete_file(f_p) |
853 self.delete_file(path) | 853 self.delete_file(path) |