---
os: linux
group: edge
addons:
apt:
packages:
- libdevmapper-dev
language: rust
jobs:
fast_finish: true
allow_failures:
- env: TASK=audit
- rust: stable
env: TASK=clippy
include:
- name: "Run rustfmt on recommended development toolchain"
rust: 1.47.0
before_script:
- rustup component add rustfmt
env: TASK=travis_fmt
- name: "Run clippy on recommended development toolchain"
rust: 1.47.0
before_script:
- rustup component add clippy
env: TASK=clippy
- name: "Run all tests on lowest supported toolchain"
rust: 1.45.0
script:
- >
sudo PATH=${TRAVIS_HOME}/.cargo/bin:$PATH
make -f Makefile sudo_test
- name: "Build on stable toolchain"
rust: stable
env: TASK=build
- name: "Run all tests on stable toolchain"
rust: stable
script:
- >
sudo PATH=${TRAVIS_HOME}/.cargo/bin:$PATH
make -f Makefile sudo_test
- name: "Build docs on stable toolchain"
rust: stable
env: TASK=docs
- name: "Audit code for security advisories on stable toolchain"
rust: stable
env: TASK=audit
- name: "Run clippy on stable toolchain"
rust: stable
before_script:
- rustup component add clippy
env: TASK=clippy
- name: "run yamllint 1.23.0 on .travis.yml"
language: python
python: "3.7.6"
install: pip3 install yamllint==1.23.0
env: TASK=yamllint
branches:
only: master
script: make -f Makefile $TASK