Have a command that specifically invokes 'p4' (via system)
[gitweb.git] / contrib / fast-import / git-p4
index 3deaa42559c38484395a81d9ac0963e279878a84..08acd517ba1c1778857ec1de7802a587ac5bcaf8 100755 (executable)
@@ -70,6 +70,13 @@ def system(cmd):
     if os.system(cmd) != 0:
         die("command failed: %s" % cmd)
 
+def p4_system(cmd):
+    """Specifically invoke p4 as the system command. """
+    real_cmd = "%s %s" % ("p4", cmd)
+    if verbose:
+        print real_cmd
+    return system(real_cmd)
+
 def isP4Exec(kind):
     """Determine if a Perforce 'kind' should have execute permission