Commit fd059a3d by Stephen Fromm

Fix for issue 604

Do not switch to master branch in pull()
Add --track to git checkout, when checking out a remote branch to track.
parent 70ef8e9e
......@@ -148,10 +148,9 @@ def pull(repo, dest, branch):
else:
m = re.search( '^\s+%s$' % branch, gbranch_out, flags=re.M ) #see if we've already checked it out
if m is None:
cmd = "git checkout -b %s origin/%s" % (branch, branch)
cmd = "git checkout --track -b %s origin/%s" % (branch, branch)
else:
(out, err) = switchLocalBranch( branch )
cmd = "git pull -u origin"
cmd = subprocess.Popen(cmd, shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment