Skip to content

Commit 6aa1cfd

Browse files
committed
Fix Travis build time via caching
Signed-off-by: Stephen L. <[email protected]>
1 parent 50fc2d8 commit 6aa1cfd

1 file changed

Lines changed: 20 additions & 12 deletions

File tree

.travis.yml

Lines changed: 20 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,22 @@ sudo: required
22
dist: trusty
33
language: python
44
python: 3.5
5+
6+
# use cache for big builds like pandas
7+
cache:
8+
pip: true
9+
directories:
10+
- $HOME/.cache/pip
11+
before_cache:
12+
- rm -f $HOME/.cache/pip/log/debug.log
13+
514
notifications:
615
email: false
716
# branches: # remove travis double-check on pull requests in main repo
817
# only:
918
# - master
1019
# - /^\d\.\d+$/
20+
1121
env:
1222
- TOXENV=py26
1323
- TOXENV=py27
@@ -18,31 +28,29 @@ env:
1828
- TOXENV=pypy3
1929
- TOXENV=flake8
2030
- TOXENV=perf
31+
2132
before_install:
22-
# (mini)conda
23-
# - pip install --upgrade virtualenv
24-
# - wget http://repo.continuum.io/miniconda/Miniconda-latest-Linux-x86_64.sh -O miniconda.sh
25-
# - chmod +x miniconda.sh
26-
# - ./miniconda.sh -b -p /home/travis/miniconda
27-
# - export PATH=/home/travis/miniconda/bin:$PATH
28-
# - conda update --yes conda
2933
# fix a crash with multiprocessing on Travis
3034
- sudo rm -rf /dev/shm
3135
- sudo ln -s /run/shm /dev/shm
32-
# - conda install --yes python=$TRAVIS_PYTHON_VERSION codecov
36+
# install codecov
3337
- pip install codecov
38+
3439
install:
35-
# - conda install --yes python=$TRAVIS_PYTHON_VERSION pandas
40+
# install big packages (they are cached to minimize build time)
41+
# if issues, clear cache
42+
# https://docs.travis-ci.com/user/caching/#Clearing-Caches
3643
- pip install pandas
37-
# - conda install --yes python=$TRAVIS_PYTHON_VERSION 'coverage<4' coveralls
44+
# Coverage install
3845
- pip install tox 'coverage<4' coveralls
39-
# Coverage packages as per https://gist.github.com/dan-blanchard/7045057
40-
# - conda install --yes -c dan_blanchard python-coveralls nose-cov
46+
# install this package (tqdm) into the environment
4147
- python setup.py install
48+
4249
# run tests
4350
script:
4451
- tox
4552
# submit coverage
53+
4654
after_success:
4755
- coveralls
4856
- codecov

0 commit comments

Comments
 (0)