From 22f2e97fb8853e7d31690124e7d1c5ed329b1749 Mon Sep 17 00:00:00 2001 From: Folkert Date: Mon, 8 Jan 2024 15:04:09 +0100 Subject: [PATCH] enable clippy on CI --- .github/workflows/checks.yaml | 60 ++++++++++++++++------------------- 1 file changed, 28 insertions(+), 32 deletions(-) diff --git a/.github/workflows/checks.yaml b/.github/workflows/checks.yaml index 24bae9b7..2478b6e7 100644 --- a/.github/workflows/checks.yaml +++ b/.github/workflows/checks.yaml @@ -76,38 +76,34 @@ jobs: files: lcov.info fail_ci_if_error: false - # obviously we want this in the future, but right now there are a bunch of clippy failures - # clippy: - # name: Clippy - # strategy: - # matrix: - # include: - # - target: x86_64-unknown-linux-gnu - # runs-on: ubuntu-latest - # steps: - # - name: Checkout sources - # uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 - # with: - # persist-credentials: false - # - name: Install rust toolchain - # uses: dtolnay/rust-toolchain@be73d7920c329f220ce78e0234b8f96b7ae60248 - # with: - # toolchain: stable - # components: clippy - # targets: ${{matrix.target}} - # - name: Rust cache - # uses: Swatinem/rust-cache@3cf7f8cc28d1b4e7d01e3783be10a97d55d483c8 - # with: - # shared-key: "stable-${{matrix.target}}" - # - # - name: Run clippy - # run: cargo clippy --target ${{matrix.target}} --workspace --all-targets --all-features -- -D warnings - # - name: Run clippy (fuzzers) - # run: cargo clippy --target ${{matrix.target}} --manifest-path ./fuzz/Cargo.toml --all-targets -- -D warnings - # if: ${{matrix.fuzzer}} - # - name: Run clippy (fuzz_rand_shim) - # run: cargo clippy --target ${{matrix.target}} --manifest-path ./fuzz/fuzz_rand_shim/Cargo.toml --all-targets -- -D warnings - # if: ${{matrix.fuzzer}} + clippy: + name: Clippy + strategy: + matrix: + include: + - target: x86_64-unknown-linux-gnu + runs-on: ubuntu-latest + steps: + - name: Checkout sources + uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 + with: + persist-credentials: false + - name: Install rust toolchain + uses: dtolnay/rust-toolchain@be73d7920c329f220ce78e0234b8f96b7ae60248 + with: + toolchain: stable + components: clippy + targets: ${{matrix.target}} + - name: Rust cache + uses: Swatinem/rust-cache@3cf7f8cc28d1b4e7d01e3783be10a97d55d483c8 + with: + shared-key: "stable-${{matrix.target}}" + + - name: Run clippy + run: cargo clippy --target ${{matrix.target}} --workspace --all-targets --all-features -- -D warnings + - name: Run clippy (fuzzers) + run: cargo clippy --target ${{matrix.target}} --manifest-path ./fuzz/Cargo.toml --all-targets -- -D warnings + if: ${{matrix.fuzzer}} fuzz: name: Smoke-test fuzzing targets