Skip to content

Commit

Permalink
ci(caching): split caches by matrix variables (#3257)
Browse files Browse the repository at this point in the history
Previously, some of the caches for these job runs were overlapping. By incorporating the relevant matrix variables into the cache key, every instance of this job gets its own cache.
  • Loading branch information
thomaseizinger authored Dec 20, 2022
1 parent 929cbb4 commit 13a59a3
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@ jobs:

- uses: Swatinem/rust-cache@359a70e43a0bb8a13953b04a90f76428b4959bb6 # v2.2.0
with:
key: ${{ matrix.target }}
save-if: ${{ github.ref == 'refs/heads/master' }}

- run: cargo check --package libp2p --all-features --target=${{ matrix.target }}
Expand Down Expand Up @@ -144,6 +145,7 @@ jobs:

- uses: Swatinem/rust-cache@359a70e43a0bb8a13953b04a90f76428b4959bb6 # v2.2.0
with:
key: ${{ matrix.features }}
save-if: ${{ github.ref == 'refs/heads/master' }}

- run: cargo check --package libp2p --features="${{ matrix.features }}"
Expand Down

0 comments on commit 13a59a3

Please sign in to comment.