From: Simon Hausmann Date: Fri, 25 May 2007 08:28:46 +0000 (+0200) Subject: Make --with-origin also work without origin :) X-Git-Tag: v1.5.3-rc0~65^2^2~55 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/417a7a6fc8c3d77e3e9a3bb0e11cb2eea978e20b Make --with-origin also work without origin :) Signed-off-by: Simon Hausmann --- diff --git a/contrib/fast-import/git-p4 b/contrib/fast-import/git-p4 index e8a5c1fa31..30ee68c609 100755 --- a/contrib/fast-import/git-p4 +++ b/contrib/fast-import/git-p4 @@ -846,8 +846,9 @@ class P4Sync(Command): self.refPrefix = "refs/heads/" if self.syncWithOrigin: - print "Syncing with origin first as requested by calling git fetch origin" - system("git fetch origin") + if gitBranchExists("origin"): + print "Syncing with origin first as requested by calling git fetch origin" + system("git fetch origin") createP4HeadRef = False;