[PATCH] Add the option to not sync after a submitting to Perforce.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



When p4->git syncing occurs not on the users machine, but on a central
mirror server there is no local remote.  When a user performs a
'git p4 submit' in this configuration after successfully applying the
patches the p4 submit command will then output a failure because it could
not p4 sync.  This causes users to think their submit failed when in
fact it was successful.

Signed-off-by: Benjamin C Meyer <bmeyer@xxxxxxx>
---
 contrib/fast-import/git-p4 |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/contrib/fast-import/git-p4 b/contrib/fast-import/git-p4
index d42b865..2a9771b 100755
--- a/contrib/fast-import/git-p4
+++ b/contrib/fast-import/git-p4
@@ -823,6 +823,9 @@ class P4Submit(Command):
             print "All changes applied!"
             chdir(self.oldWorkingDirectory)
 
+            if gitConfig("git-p4.syncAfterSubmit") == "false":
+                return True
+
             sync = P4Sync()
             sync.run([])
 
-- 
1.7.1

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]