Improve CI
This commit is contained in:
parent
d6375c8967
commit
fe1c409165
19
.travis.yml
19
.travis.yml
|
|
@ -11,6 +11,14 @@ env:
|
|||
- MOLECULE_DISTRO: ubuntu-18.04
|
||||
- MOLECULE_DISTRO: ubuntu-20.04
|
||||
|
||||
before_install:
|
||||
- |
|
||||
if ! git diff --name-only $TRAVIS_COMMIT_RANGE | grep -qvE '(.md)|(.pdf)'
|
||||
then
|
||||
echo "Only doc files were updated, not running the CI."
|
||||
exit
|
||||
fi
|
||||
|
||||
cache:
|
||||
directories:
|
||||
- $HOME/.cache/pre-commit
|
||||
|
|
@ -18,18 +26,13 @@ cache:
|
|||
jobs:
|
||||
include:
|
||||
- name: lint with pre-commit
|
||||
install: skip
|
||||
before_install: skip
|
||||
script:
|
||||
- pip3 install pre-commit
|
||||
- pip install pre-commit
|
||||
- pre-commit run -c .travis-pre-commit-config.yaml -a
|
||||
|
||||
script:
|
||||
- |
|
||||
if ! git diff --name-only $TRAVIS_COMMIT_RANGE | grep -qvE '(.md)|(.pdf)'
|
||||
then
|
||||
echo "Only doc files were updated, not running the CI."
|
||||
exit
|
||||
fi
|
||||
- pip3 install -r requirements.txt
|
||||
- export ANSIBLE_STRATEGY=mitogen_linear
|
||||
- export ANSIBLE_STRATEGY_PLUGINS=${VIRTUAL_ENV}/lib/python${TRAVIS_PYTHON_VERSION}/site-packages/ansible_mitogen/plugins/strategy
|
||||
- molecule --version
|
||||
|
|
|
|||
Loading…
Reference in New Issue