CI: Add a clippy job

Uses stable clippy for the time being

Otherwise we'll get warnings about lint names being deprecated without
being able to fix it while still being able to compile on stable.

This will solve itself once the new lint names move to stable and we can
switch to them.
This commit is contained in:
Jordan Petridis 2018-11-09 18:44:26 +02:00
parent 9d5347d7b5
commit 4ce27c130b
No known key found for this signature in database
GPG key ID: 902CC06D159744F5

View file

@ -1,6 +1,7 @@
stages: stages:
- "lint" - "lint"
- "test" - "test"
- "extras"
.tarball_setup: &setup .tarball_setup: &setup
variables: variables:
@ -74,3 +75,12 @@ rustfmt:
- rustup component add rustfmt - rustup component add rustfmt
- cargo fmt --version - cargo fmt --version
- cargo fmt -- --color=always --check - cargo fmt -- --color=always --check
clippy:
image: "rust:slim"
stage: 'extras'
<<: *setup
script:
- rustup component add clippy-preview
- cargo clippy --version
- cargo clippy --color=always --all --all-features