remote-hg: remove files before modifications

Otherwise replacing a file with a directory doesn't work. Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Felipe Contreras committed May 24, 2013 at 21:29 UTC 66f46aa14fa48e5d17885b46e80250e155c255e3
1 file changed +2 -2
contrib/remote-helpers/git-remote-hg
+2 -2
@@ -510,10 +510,10 @@ def export_ref(repo, name, kind, head):
510 if len(parents) > 1:
511 print "merge :%s" % (rev_to_mark(parents[1]))
512
513 - for f in modified_final:
514 - print "M %s :%u %s" % f
513 for f in removed:
514 print "D %s" % (fix_file_path(f))
515 + for f in modified_final:
516 + print "M %s :%u %s" % f
517 print
518
519 progress = (rev - tip)