Skip to content

Commit

Permalink
Only run clippy and rustfmt on CI if the component is available
Browse files Browse the repository at this point in the history
  • Loading branch information
gnzlbg committed Mar 21, 2019
1 parent 8cb8db4 commit 801114a
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -129,16 +129,19 @@ matrix:
- name: "rustfmt"
install: true
rust: nightly
before_script: rustup component add rustfmt-preview
script: cargo fmt --all -- --check
script: |
if rustup component add rustfmt-preview ; then
cargo fmt --all -- --check
fi
- name: "clippy"
install: true
rust: nightly
# allow(clippy::all) fails in the syscrate, so we can't use --all here:
script: |
if rustup component add clippy-preview; then
if rustup component add clippy-preview ; then
cargo clippy -p jemalloc-sys -- -D clippy::pedantic
cargo clippy -p jemallocator -- -D clippy::pedantic
cargo clippy -p jemallocator-global -- -D clippy::pedantic
cargo clippy -p jemalloc-ctl -- -D clippy::pedantic
fi
- name: "Shellcheck"
Expand Down

0 comments on commit 801114a

Please sign in to comment.