diff --git a/.github/workflows/cargo-lint.yml b/.github/workflows/cargo-lint.yml index 3973f42..5c7f1b7 100644 --- a/.github/workflows/cargo-lint.yml +++ b/.github/workflows/cargo-lint.yml @@ -15,7 +15,7 @@ env: CARGO_TERM_COLOR: always jobs: - lint: + clippy: runs-on: ubuntu-latest strategy: matrix: @@ -40,5 +40,19 @@ jobs: - name: clippy run: cargo clippy --no-deps ${{ matrix.target }} --verbose -- -Dwarnings - - name: fmt - run: cargo fmt --all --check --verbose + fmt: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - uses: actions/cache@v4 + with: + path: target/ + key: cargo-lint-${{ hashFiles('Cargo.lock') }} + restore-keys: | + cargo-lint-${{ hashFiles('Cargo.lock') }} + cargo-lint- + cargo- + + - name: fmt + run: cargo fmt --all --check --verbose