From 02837ace9820cd6007f3ee1248cacb03c5d6c200 Mon Sep 17 00:00:00 2001 From: Tamir Duberstein Date: Sun, 19 Nov 2023 13:26:26 -0500 Subject: [PATCH] .github: add rust cache action This should reduce CI time. --- .github/workflows/test.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 5968282..d23939f 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -26,6 +26,9 @@ jobs: - uses: dtolnay/rust-toolchain@master with: toolchain: ${{ matrix.rust }} + - uses: Swatinem/rust-cache@v2 + with: + key: ${{ matrix.profile }} - name: Build & test run: | cargo build --profile=${{ matrix.profile }} @@ -61,6 +64,7 @@ jobs: steps: - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@stable + - uses: Swatinem/rust-cache@v2 - run: cargo clippy --no-deps --all-targets --all-features -- -A unknown_lints -D warnings rustdoc: name: Generate documentation @@ -70,4 +74,5 @@ jobs: steps: - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@stable + - uses: Swatinem/rust-cache@v2 - run: cargo doc --no-deps