travis: osx: speedup install stage

Signed-off-by: Ruslan Kuprieiev <[email protected]>
This commit is contained in:
Ruslan Kuprieiev
2019-08-10 04:15:22 +03:00
parent 60bcd3dc13
commit 3f19036646
5 changed files with 95 additions and 111 deletions
+6 -7
View File
@@ -1,3 +1,5 @@
#!/bin/bash
set -e
set -x
@@ -9,16 +11,13 @@ else
which pip
fi
if [[ -z "$PYTHON_VER" ]]; then
exit 0
fi
if [[ "$TRAVIS_OS_NAME" == "windows" ]]; then
if [[ "$(python -c 'import sys; print(sys.version[:3])')" != "$PYTHON_VER" ]]; then
py_ver="$(python -c 'import sys; print(sys.version[0])')"
if [[ -n "$PY2" ]]; then
if [[ "$py_ver" != "2" ]]; then
exit 1
fi
else
if [[ "$(python --version 2>&1)" != "Python $PYTHON_VER" ]]; then
if [[ "$py_ver" != "3" ]]; then
exit 1
fi
fi