Fix single branch import into remotes
Signed-off-by: Marius Storm-Olsen <mstormo_git@storm-olsen.com>
This commit is contained in:
parent
98ad4faf95
commit
db775559c2
@ -1014,7 +1014,7 @@ class P4Sync(Command):
|
|||||||
if self.importIntoRemotes:
|
if self.importIntoRemotes:
|
||||||
self.refPrefix = "refs/remotes/p4/"
|
self.refPrefix = "refs/remotes/p4/"
|
||||||
else:
|
else:
|
||||||
self.refPrefix = "refs/heads/"
|
self.refPrefix = "refs/heads/p4/"
|
||||||
|
|
||||||
if self.syncWithOrigin and self.hasOrigin:
|
if self.syncWithOrigin and self.hasOrigin:
|
||||||
if not self.silent:
|
if not self.silent:
|
||||||
@ -1022,7 +1022,7 @@ class P4Sync(Command):
|
|||||||
system("git fetch origin")
|
system("git fetch origin")
|
||||||
|
|
||||||
if len(self.branch) == 0:
|
if len(self.branch) == 0:
|
||||||
self.branch = self.refPrefix + "p4/master"
|
self.branch = self.refPrefix + "master"
|
||||||
if gitBranchExists("refs/heads/p4") and self.importIntoRemotes:
|
if gitBranchExists("refs/heads/p4") and self.importIntoRemotes:
|
||||||
system("git update-ref %s refs/heads/p4" % self.branch)
|
system("git update-ref %s refs/heads/p4" % self.branch)
|
||||||
system("git branch -D p4");
|
system("git branch -D p4");
|
||||||
|
Loading…
Reference in New Issue
Block a user