git-p4: Fix sync errors due to new server version
authorPal-Kristian Engstad <pal_engstad@naughtydog.com>
Fri, 22 Jan 2010 02:33:00 +0000 (18:33 -0800)
committerJunio C Hamano <gitster@pobox.com>
Mon, 1 Feb 2010 20:08:14 +0000 (12:08 -0800)
Fix sync errors due to new Perforce servers.

The P4D/NTX64/2009.2/228098 (2009/12/16) server reports
'move/delete' instead of 'delete'. This causes the Perforce
depot and the git repo to get out of sync. Fixed by adding
the new status string.

Signed-off-by: Pal-Kristian Engstad <pal_engstad@naughtydog.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
contrib/fast-import/git-p4

index d1512e0..e7c4814 100755 (executable)
@@ -1037,7 +1037,7 @@ class P4Sync(Command):
 
             if includeFile:
                 filesForCommit.append(f)
 
             if includeFile:
                 filesForCommit.append(f)
-                if f['action'] not in ('delete', 'purge'):
+                if f['action'] not in ('delete', 'move/delete', 'purge'):
                     filesToRead.append(f)
                 else:
                     filesToDelete.append(f)
                     filesToRead.append(f)
                 else:
                     filesToDelete.append(f)