{"thread":{"id":"24010","subject":"[PATCH] Add the option to not sync after a submitting to Perforce.","startedAt":"2010-06-04T17:33:04Z","lastAt":"2010-06-04T17:33:04Z","messageCount":1,"participants":["Benjamin C Meyer"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"142995","messageId":"1275672784-16371-1-git-send-email-bmeyer@rim.com","threadId":"24010","inReplyTo":null,"subject":"[PATCH] Add the option to not sync after a submitting to Perforce.","fromName":"Benjamin C Meyer","fromEmail":"bmeyer@rim.com","sentAt":"2010-06-04T17:33:04Z","receivedAt":"2010-06-04T17:33:04Z","isPatch":true,"sender":{"key":"bmeyer@rim.com","avatar":null},"body":"When p4->git syncing occurs not on the users machine, but on a central\nmirror server there is no local remote.  When a user performs a\n'git p4 submit' in this configuration after successfully applying the\npatches the p4 submit command will then output a failure because it could\nnot p4 sync.  This causes users to think their submit failed when in\nfact it was successful.\n\nSigned-off-by: Benjamin C Meyer <bmeyer@rim.com>\n---\n contrib/fast-import/git-p4 |    3 +++\n 1 files changed, 3 insertions(+), 0 deletions(-)\n\ndiff --git a/contrib/fast-import/git-p4 b/contrib/fast-import/git-p4\nindex d42b865..2a9771b 100755\n--- a/contrib/fast-import/git-p4\n+++ b/contrib/fast-import/git-p4\n@@ -823,6 +823,9 @@ class P4Submit(Command):\n             print \"All changes applied!\"\n             chdir(self.oldWorkingDirectory)\n \n+            if gitConfig(\"git-p4.syncAfterSubmit\") == \"false\":\n+                return True\n+\n             sync = P4Sync()\n             sync.run([])\n \n-- \n1.7.1\n"}]}