From: Amadeusz Żołnowski Date: Fri, 19 Feb 2016 21:57:54 GMT Subject: [PATCH] git-p4.py: Make submit working on bare repository Message-ID: <1455919074-5683-1-git-send-email-aidecoe@aidecoe.name> In-Reply-To: git-p4 can be successfully used from bare repository (which may act as a bridge between Perforce repository and pure Git repositories). After submitting changelist to Perforce, git-p4 performs unconditional rebase which obviously fails. Perform rebase only on non-bare repositories, so submit command can be successful on bare repository. Signed-off-by: Amadeusz Żołnowski --- git-p4.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/git-p4.py b/git-p4.py index c33dece..e00cd02 100755 --- a/git-p4.py +++ b/git-p4.py @@ -2059,8 +2059,9 @@ class P4Submit(Command, P4UserMap): sync.branch = self.branch sync.run([]) - rebase = P4Rebase() - rebase.rebase() + if not gitConfigBool("core.bare"): + rebase = P4Rebase() + rebase.rebase() else: if len(applied) == 0: -- 2.7.0