Skip to content

Commit

Permalink
Make the flake8 job use a separate cache
Browse files Browse the repository at this point in the history
The CACHE_NAME environment variable hack is recommended by
https://docs.travis-ci.com/user/caching/

Also, AFAIU the before_cache: rm pip/debug.log is needed only if you
manually try to cache the ~/.cache/pip directory, and shouldn't be
needed for cache: pip.

Also I like 2-space indents in YAML files so there.
  • Loading branch information
mgedmin committed Apr 10, 2020
1 parent bfa427e commit b6b9920
Showing 1 changed file with 13 additions and 14 deletions.
27 changes: 13 additions & 14 deletions .travis.yml
@@ -1,28 +1,27 @@
language: python
python:
- 2.7
- 3.5
- 3.6
- 3.7
- 3.8
- pypy
- 2.7
- 3.5
- 3.6
- 3.7
- 3.8
- pypy
jobs:
include:
- name: flake8
install: pip install flake8
script: flake8 src setup.py
after_success:
env: CACHE_NAME=flake8
install:
- pip install -U pip setuptools
- pip install -U coverage coveralls
- pip install -U -e .[test,docs]
- pip install -U pip setuptools
- pip install -U coverage coveralls
- pip install -U -e .[test,docs]
script:
- coverage run -m zope.testrunner --test-path=src
- coverage run -a -m sphinx -b doctest -d docs/_build/doctrees docs docs/_build/doctest
- coverage run -m zope.testrunner --test-path=src
- coverage run -a -m sphinx -b doctest -d docs/_build/doctrees docs docs/_build/doctest
notifications:
email: false
email: false
cache: pip
before_cache:
- rm -f $HOME/.cache/pip/log/debug.log
after_success:
- coveralls

0 comments on commit b6b9920

Please sign in to comment.