[rust] Make CI fail on warnings (#6763)
https://doc.rust-lang.org/stable/clippy/continuous_integration/github_actions.html
This commit is contained in:
7
.github/workflows/rust-lint.yml
vendored
7
.github/workflows/rust-lint.yml
vendored
@@ -15,6 +15,9 @@ concurrency:
|
||||
group: ${{ github.workflow }}-${{ github.ref }}
|
||||
cancel-in-progress: true
|
||||
|
||||
env:
|
||||
RUSTFLAGS: -D warnings
|
||||
|
||||
jobs:
|
||||
lint:
|
||||
runs-on: ubuntu-latest
|
||||
@@ -33,9 +36,9 @@ jobs:
|
||||
~/.cargo/git
|
||||
target
|
||||
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
|
||||
|
||||
|
||||
- run: cargo fmt --check
|
||||
|
||||
- run: cargo clippy
|
||||
- run: cargo clippy --all-targets --all-features
|
||||
|
||||
- run: cargo build
|
||||
|
||||
Reference in New Issue
Block a user