aboutsummaryrefslogtreecommitdiffstats
path: root/.travis
diff options
context:
space:
mode:
authorPaul Kehrer <paul.l.kehrer@gmail.com>2014-01-07 21:41:15 -0600
committerPaul Kehrer <paul.l.kehrer@gmail.com>2014-01-08 20:01:43 -0600
commit0b06e554725585b8accb68e70bc95452d5bacc94 (patch)
tree5b601c62badd9d5a1b6da325e5b30a3c99cb0240 /.travis
parent43cf688e885668198bc966b1cf3a4a425a60f1a6 (diff)
downloadcryptography-0b06e554725585b8accb68e70bc95452d5bacc94.tar.gz
cryptography-0b06e554725585b8accb68e70bc95452d5bacc94.tar.bz2
cryptography-0b06e554725585b8accb68e70bc95452d5bacc94.zip
support osx and linux on travis
Diffstat (limited to '.travis')
-rwxr-xr-x.travis/install.sh67
1 files changed, 66 insertions, 1 deletions
diff --git a/.travis/install.sh b/.travis/install.sh
index 4aa39799..d25ed941 100755
--- a/.travis/install.sh
+++ b/.travis/install.sh
@@ -3,10 +3,75 @@
set -e
set -x
-if [[ "${OPENSSL}" == "0.9.8" ]]; then
+if [[ "${OPENSSL}" == "0.9.8" && "$(uname -s)" != "Darwin" ]]; then
sudo add-apt-repository "deb http://archive.ubuntu.com/ubuntu/ lucid main"
sudo apt-get -y update
sudo apt-get install -y --force-yes libssl-dev/lucid
fi
+if [[ "$(uname -s)" == "Darwin" ]]; then
+ brew update
+ brew install pyenv
+ if which pyenv > /dev/null; then eval "$(pyenv init -)"; fi
+ case "${TOX_ENV}" in
+ py26)
+ sudo easy_install pip
+ sudo pip install setuptools --no-use-wheel --upgrade
+ sudo pip install virtualenv
+ ;;
+ py27)
+ sudo easy_install pip
+ sudo pip install setuptools --no-use-wheel --upgrade
+ sudo pip install virtualenv
+ ;;
+ pypy)
+ pyenv install pypy-2.2.1
+ pyenv global pypy-2.2.1
+ pip install virtualenv
+ ;;
+ py32)
+ pyenv install 3.2.5
+ pyenv global 3.2.5
+ pip install virtualenv
+ ;;
+ py33)
+ pyenv install 3.3.2
+ pyenv global 3.3.2
+ pip install virtualenv
+ ;;
+ esac
+ pyenv rehash
+else
+ # add mega-python ppa
+ sudo add-apt-repository -y ppa:fkrull/deadsnakes
+ sudo apt-get -y update
+
+ case "${TOX_ENV}" in
+ py26)
+ sudo apt-get install python2.6 python2.6-dev
+ ;;
+ py32)
+ sudo apt-get install python3.2 python3.2-dev
+ ;;
+ py33)
+ sudo apt-get install python3.3 python3.3-dev
+ ;;
+ py3pep8)
+ sudo apt-get install python3.3 python3.3-dev
+ ;;
+ pypy)
+ sudo add-apt-repository -y ppa:pypy/ppa
+ sudo apt-get -y update
+ sudo apt-get install -y --force-yes pypy pypy-dev
+ ;;
+ esac
+ sudo pip install virtualenv
+fi
+
+virtualenv ~/.venv
+source ~/.venv/bin/activate
pip install tox coveralls
+
+if [[ "$(uname -s)" == "Darwin" ]]; then
+ pyenv rehash
+fi