Skip to content

Commit 26eb3ac

Browse files
committed
fix install script
1 parent 7641557 commit 26eb3ac

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

utilities/install.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
import os, sys
66
from shutil import copyfile
77

8-
branch = "development"
8+
branch = None
99

1010
#by default clones branch (which can be passed as a parameter python install.py branch test_branch)
1111
#if branch doesnt exist clones the default_branch
@@ -26,10 +26,10 @@ def checkout(folder, default_branch, cwdp):
2626
os.chdir(newPath)
2727
python_git=subprocess.Popen("git branch -a",shell=True,stdout=subprocess.PIPE,stderr=subprocess.PIPE)
2828
outstd,errstd=python_git.communicate()
29-
if default_branch in str(outstd):
30-
subprocess.call(['git', 'checkout', default_branch], cwd='./')
31-
else:
29+
if branch and branch in str(outstd):
3230
subprocess.call(['git', 'checkout', branch], cwd='./')
31+
else:
32+
subprocess.call(['git', 'checkout', default_branch], cwd='./')
3333
os.chdir(currentPath)
3434

3535
def main(argv):

0 commit comments

Comments
 (0)