File tree Expand file tree Collapse file tree 1 file changed +12
-8
lines changed
Expand file tree Collapse file tree 1 file changed +12
-8
lines changed Original file line number Diff line number Diff line change @@ -25,10 +25,12 @@ error() { log "ERROR: $@" >&2; }
2525fatal () { error " $@ " ; exit 1; }
2626try () { " $@ " || fatal " '$@ ' failed" ; }
2727
28+ NOVENV=
2829PY_VER=2
2930API_VER=3
30- while getopts :p :a: opt " $@ " ; do
31+ while getopts :np :a: opt " $@ " ; do
3132 case $opt in
33+ n) NOVENV=1;;
3234 p) PY_VER=$OPTARG ;;
3335 a) API_VER=$OPTARG ;;
3436 :) fatal " Option -${OPTARG} requires a value" ;;
@@ -143,15 +145,17 @@ EOF
143145log " Config file content ($CONFIG ):"
144146log < $CONFIG
145147
146- log " Creating Python virtualenv..."
147- try " $VENV_CMD " " $VENV "
148- . " $VENV " /bin/activate || fatal " failed to activate Python virtual environment"
148+ if [ -z " $NOVENV " ]; then
149+ log " Creating Python virtualenv..."
150+ try " $VENV_CMD " " $VENV "
151+ . " $VENV " /bin/activate || fatal " failed to activate Python virtual environment"
149152
150- log " Installing dependencies into virtualenv..."
151- try pip install -rrequirements.txt
153+ log " Installing dependencies into virtualenv..."
154+ try pip install -rrequirements.txt
152155
153- log " Installing into virtualenv..."
154- try pip install -e .
156+ log " Installing into virtualenv..."
157+ try pip install -e .
158+ fi
155159
156160log " Pausing to give GitLab some time to finish starting up..."
157161sleep 30
You can’t perform that action at this time.
0 commit comments