ruwuma/.travis.yml
2020-04-03 19:11:24 +02:00

34 lines
765 B
YAML

language: "rust"
cache: "cargo"
rust:
- 1.40.0
- stable
- beta
- nightly
jobs:
allow_failures:
- rust: nightly
fast_finish: true
before_script:
- rustup component add rustfmt
- rustup component add clippy || true
- |
if [ "$TRAVIS_RUST_VERSION" == "stable" ]; then
cargo install --force cargo-audit
fi
- cargo generate-lockfile
script:
- |
if [ "$TRAVIS_RUST_VERSION" == "stable" ]; then
cargo audit
fi
- cargo fmt --all -- --check
- |
if ( rustup component list | grep -q clippy ); then
cargo clippy --all --all-targets --all-features -- -D warnings
fi
- cargo build --all --verbose
- cargo test --all --verbose
if: "type != push OR (tag IS blank AND branch = master)"