From 5f91a17ea8eea36fce1b00ba07fbbebf59ee6809 Mon Sep 17 00:00:00 2001 From: Alexander van Saase Date: Wed, 21 Aug 2024 23:37:38 +0200 Subject: [PATCH] Split formatting and linting jobs --- .github/workflows/ci.yaml | 23 +++++++++++++++++++---- 1 file changed, 19 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 8c1d221..e1e4282 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -50,7 +50,7 @@ jobs: - name: Run cargo test run: cargo test --all-targets --all-features - lints: + formatting: name: Lints runs-on: windows-latest steps: @@ -58,9 +58,9 @@ jobs: uses: actions/checkout@v4 - name: Install toolchain - uses: dtolnay/rust-toolchain@stable + uses: dtolnay/rust-toolchain@nightly with: - components: rustfmt, clippy + components: rustfmt - name: Cache dependencies uses: Swatinem/rust-cache@v2 @@ -68,5 +68,20 @@ jobs: - name: Run cargo fmt run: cargo +nightly fmt --check + lints: + name: Lints + runs-on: windows-latest + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Install toolchain + uses: dtolnay/rust-toolchain@stable + with: + components: clippy + + - name: Cache dependencies + uses: Swatinem/rust-cache@v2 + - name: Run cargo clippy - run: cargo clippy --all-targets --all-features -- -D warnings \ No newline at end of file + run: cargo clippy --all-targets --all-features -- -D warnings