travis: use stable rustfmt and switch to clippy-preview

This commit is contained in:
Victor Berger 2018-09-27 12:18:54 +02:00
parent 6328f68b71
commit cd77229199
2 changed files with 6 additions and 4 deletions

View File

@ -53,7 +53,7 @@ env:
matrix:
include:
# special features for lint & fmt
- rust: nightly
- rust: stable
env: FEATURES="cargo-fmt"
- rust: nightly
env: FEATURES="cargo-clippy"
@ -81,10 +81,9 @@ script:
vagga cargo-$TRAVIS_RUST_VERSION doc --no-deps
;;
"cargo-fmt")
vagga cargo-$TRAVIS_RUST_VERSION fmt -- --write-mode=diff
vagga cargo-$TRAVIS_RUST_VERSION fmt -- --check
;;
"cargo-clippy")
vagga cargo-$TRAVIS_RUST_VERSION install -f clippy &&
vagga cargo-$TRAVIS_RUST_VERSION clippy --all-features -- -D warnings
;;
"anvil")

View File

@ -19,6 +19,9 @@ containers:
- !Container base
- !Env HOME: /work/.vagga/stable-home
- !Sh curl https://sh.rustup.rs -sSf | sh -s -- -y --default-host x86_64-unknown-linux-gnu --default-toolchain stable --no-modify-path
- !Env PATH: /bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:/work/.vagga/stable-home/.cargo/bin:/work/.vagga/stable-home/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/bin/
- !Sh rustup self update
- !Sh rustup component add rustfmt-preview
beta:
auto-clean: true
@ -45,7 +48,7 @@ containers:
- !Sh curl https://sh.rustup.rs -sSf | sh -s -- -y --default-host x86_64-unknown-linux-gnu --default-toolchain nightly --no-modify-path
- !Env PATH: /bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:/work/.vagga/nightly-home/.cargo/bin:/work/.vagga/nightly-home/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/bin/
- !Sh rustup self update
- !Sh rustup component add rustfmt-preview
- !Sh rustup component add clippy-preview
commands:
update-stable: !Command