travis2bash python options fix
This commit is contained in:
parent
829e05599a
commit
a1dfb3442a
|
@ -161,8 +161,10 @@ if [[ "$(declare -p travis_python)" =~ "declare -a" ]]; then
|
||||||
# strip quotes
|
# strip quotes
|
||||||
temp="${pv%\"}"
|
temp="${pv%\"}"
|
||||||
pv="${temp#\"}"
|
pv="${temp#\"}"
|
||||||
# strip crap
|
|
||||||
options=$(echo "$pv"|cut -d_ -f2-)
|
options=$(echo "$pv"|cut -d_ -f2-)
|
||||||
|
if [ "$options" == "$pv" ]; then
|
||||||
|
unset options
|
||||||
|
fi
|
||||||
if [[ "$options" == with* ]]; then
|
if [[ "$options" == with* ]]; then
|
||||||
options="--$(echo "$options"|cut -d_ -f2-|tr -- '_' '-')"
|
options="--$(echo "$options"|cut -d_ -f2-|tr -- '_' '-')"
|
||||||
fi
|
fi
|
||||||
|
@ -176,7 +178,11 @@ if [[ "$(declare -p travis_python)" =~ "declare -a" ]]; then
|
||||||
sudo apt -y install "python$pv" "python${pv}-dev"
|
sudo apt -y install "python$pv" "python${pv}-dev"
|
||||||
#fi
|
#fi
|
||||||
|
|
||||||
virtualenv_init "$ppath" "$pv" "$options"
|
if [ -n "$options" ]; then
|
||||||
|
virtualenv_init "$ppath" "$pv" "$options"
|
||||||
|
else
|
||||||
|
virtualenv_init "$ppath" "$pv"
|
||||||
|
fi
|
||||||
virtualenv_activate "$pv"
|
virtualenv_activate "$pv"
|
||||||
python_run "$ppath" "$pv"
|
python_run "$ppath" "$pv"
|
||||||
deactivate
|
deactivate
|
||||||
|
|
Loading…
Reference in New Issue
Block a user