-
Notifications
You must be signed in to change notification settings - Fork 9
/
.travis.yml
94 lines (92 loc) · 3.23 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
language: python
python:
- "3.6"
# This is copied from ObsPy: https://raw.githubusercontent.com/obspy/obspy/master/.travis.yml
install:
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then
export OS="MacOSX";
else
export OS="Linux";
fi
- |
if [[ "$ARCHITECTURE_32BIT" == "True" ]]; then
export ARCH=""
# OPT is used by setuptools patches contained in newer numpy versions
# used by obspy when running pip install --no-deps .
export OPT="-m32"
# workaround for sudo dpkg --add-architecture i386
# be sure multiarch is the only file in this directory
ls /etc/dpkg/dpkg.cfg.d/
# multiarch must contain foreign-architecture i386. If not it will
# error later and you need to do the following and add sudo: true
#sudo sh -c "echo 'foreign-architecture i386' > /etc/dpkg/dpkg.cfg.d/multiarch"
cat /etc/dpkg/dpkg.cfg.d/multiarch
else
export ARCH="_64"
fi
- if [[ "${PYTHON_VERSION:0:1}" == '2' ]]; then
wget https://repo.continuum.io/miniconda/Miniconda2-latest-${OS}-x86${ARCH}.sh -O miniconda.sh;
else
wget https://repo.continuum.io/miniconda/Miniconda3-latest-${OS}-x86${ARCH}.sh -O miniconda.sh;
fi
- bash miniconda.sh -b -p $HOME/miniconda
- rm miniconda.sh
- export PATH="$HOME/miniconda/bin:$PATH"
- hash -r
- conda config --set always_yes yes --set changeps1 no
- conda update -q conda
# Useful for debugging any issues with conda
- conda info -a
- |
if [[ "$MINIMUM_DEPENDENCIES" == 'True' ]]; then
NUMPY="numpy=1.6.2"
SCIPY="scipy=0.11.0"
MATPLOTLIB="matplotlib=1.1.1"
# no basemap version works with this old numpy, so leave out
BASEMAP=""
PYPROJ="pyproj"
# ancient matplotlib needs to be turned to AGG before anything else,
# otherwise it tries to import incompatible version of Qt as a backend
# and hick-ups..
mkdir -p $HOME/.matplotlib
echo 'backend:AGG' > $HOME/.matplotlib/matplotlibrc
elif [[ "${PYTHON_VERSION}" == '3.3' ]]; then
# Let conda resolve to the latest versions.
NUMPY="numpy"
SCIPY="scipy"
MATPLOTLIB="matplotlib"
BASEMAP="basemap"
# anaconda doesn't provide pyproj for Python 3.3 anymore
PYPROJ=""
elif [[ "${PYTHON_VERSION}" == '3.4' ]]; then
# 3.4 apparently no longer get's updated packages.
# Let conda resolve to the latest versions.
NUMPY="numpy"
SCIPY="scipy"
MATPLOTLIB="matplotlib"
BASEMAP="basemap"
PYPROJ="pyproj"
elif [[ "$ARCHITECTURE_32BIT" == "True" ]]; then
# Special packages for 32bit. Also let conda resolve to the latest
# versions.
NUMPY="numpy"
SCIPY="scipy"
MATPLOTLIB="matplotlib"
BASEMAP="basemap"
PYPROJ="pyproj"
# For anything else also let conda resolve, but force matplotlib 2.
else
NUMPY="numpy"
SCIPY="scipy"
MATPLOTLIB="matplotlib>=2.0.0"
BASEMAP="basemap"
PYPROJ="pyproj"
fi
- conda env create
- source activate pyweed
- conda list
# done installing dependencies
- pip install --no-deps .
- git status
script:
- echo TODO