forked from starkit/starkit
/
.travis.yml
67 lines (54 loc) · 3.04 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
language: python
env:
global:
# The following versions are the 'default' for tests, unless
# overidden underneath. They are defined here in order to save having
# to repeat them for all configurations.
- PIP_INSTALL='pip install'
- secure: "W+8ZpAZPXi2q0dXhpPDY6IT1AWiYUdXK0KdGIPBwDOp9BR49fZSR2pO2razeSIgES6ZZdLQPxrV+SvorLegoK18I5ZkmOvCJDxl42hghSXzASFImNtM5EAY6C6pdEmnYNuahBxqL7hDRVh66DVNW0IGP3+5UIjDv31uJa65Y7KAptM8N0hdaDH/7FmBYqVsTIl8B+KOAiC5g6NXqSk5+nzwLnf32HoACS6sdZWlU0xl/xTDFcKOnTkHWtzYpCxm7RqaXoI92HgVx526sPpWs2SxvaknNMW0h0MPYbrzRs3wN+0fZXEwpzrMxnPkCuMzlKIXwyrGNLKY363rTgd9LpsTsNy+riW7r1euXyDpDspzvIY0bDisQCux8W3Qt2pZdZkGRWKc9Fmudpm6KKtm6W95vuqUODQ/wN2kL6rKuacSdXRinRrp35v+AyistPhqAXu6m8P8/7gQtwbxVD1AIOPwD/5fM8dG4ZGGAhCDVmHwhfKUiWFVKWjlHWUSVVNuNmMjf0rNOIpALJCxY7HxVT/nQzujcCglLhjkWN8XrE4j6zMi2RNzhE/a6vQThRKza9wLHxPWzXRB4NTgQFBzXh7VVtP4q1VqIcOS5/x/MjF6DeJfgC9XKRz2nXk16Isd4ZFtfGTwM3tGm7Z7RgmJ5JoioDV6Sxuq6ORfw9SPh7zg="
matrix:
- SETUP_CMD='egg_info'
matrix:
include:
# Do a coverage test in Python 2.
- python: 2.7
env: SETUP_CMD='test --coverage'
# Generate docs
- python: 2.7
env: SETUP_CMD='build_docs'
# Do a coverage test in Python 3.
- python: 3.6
env: SETUP_CMD='test --coverage'
before_install:
# Use utf8 encoding. Should be default, but this is insurance against
# future changes
- export PYTHONIOENCODING=UTF8
- wget http://repo.continuum.io/miniconda/Miniconda-latest-Linux-x86_64.sh -O miniconda.sh
- chmod +x miniconda.sh
- ./miniconda.sh -b
- export PATH=/home/travis/miniconda2/bin:$PATH
- conda update --yes conda
# UPDATE APT-GET LISTINGS
- sudo apt-get update
install:
# CONDA
- if [[ $TRAVIS_PYTHON_VERSION == 2.7 ]]; then conda env create -n starkit --file ./starkit_env27.yml;
elif [[ $TRAVIS_PYTHON_VERSION == 3.6 ]]; then conda env create -n starkit --file ./starkit_env3.yml; fi
- source activate starkit
# OPTIONAL DEPENDENCIES
# Here you can add any dependencies your package may have. You can use
# conda for packages available through conda, or pip for any other
# packages. You should leave the `numpy=$NUMPY_VERSION` in the `conda`
# install since this ensures Numpy does not get automatically upgraded.
# - if [[ $SETUP_CMD != egg_info ]]; then $CONDA_INSTALL numpy=$NUMPY_VERSION ... ; fi
# - if [[ $SETUP_CMD != egg_info ]]; then $PIP_INSTALL ...; fi
# COVERAGE DEPENDENCIES
- if [[ $SETUP_CMD == 'test --coverage' ]]; then $PIP_INSTALL coverage coveralls; fi
script:
- python setup.py $SETUP_CMD
- if [[ $SETUP_CMD == 'build_docs' ]]; then source deploy_docs.sh; fi
after_success:
# If coveralls.io is set up for this package, uncomment the line
# below and replace "packagename" with the name of your package.
# The coveragerc file may be customized as needed for your package.
# - if [[ $SETUP_CMD == 'test --coverage' ]]; then coveralls --rcfile='packagename/tests/coveragerc'; fi