From: Simon Hausmann Date: Sun, 27 May 2007 13:48:01 +0000 (+0200) Subject: Fix creation of refs/remotes/p4/HEAD symbolic ref X-Git-Url: http://crossforests.com/gitweb?a=commitdiff_plain;h=175ea5930546ce330f15d6ca07b9ce9ef39ae726;p=python%2Ffast-export.git Fix creation of refs/remotes/p4/HEAD symbolic ref --- diff --git a/git-p4 b/git-p4 index dbd5b3b..aeefadc 100755 --- a/git-p4 +++ b/git-p4 @@ -858,8 +858,6 @@ class P4Sync(Command): print "Syncing with origin first by calling git fetch origin" system("git fetch origin") - createP4HeadRef = False; - if len(self.branch) == 0: self.branch = self.refPrefix + "master" if gitBranchExists("refs/heads/p4") and self.importIntoRemotes: @@ -867,7 +865,7 @@ class P4Sync(Command): system("git branch -D p4"); # create it /after/ importing, when master exists if not gitBranchExists(self.refPrefix + "HEAD") and self.importIntoRemotes: - createP4HeadRef = True + system("git symbolic-ref %sHEAD %s" % (self.refPrefix, self.branch)) if len(args) == 0: if self.hasOrigin: @@ -1117,9 +1115,6 @@ class P4Sync(Command): self.gitOutput.close() self.gitError.close() - if createP4HeadRef: - system("git symbolic-ref %sHEAD %s" % (self.refPrefix, self.branch)) - return True class P4Rebase(Command):