Skip to content

Commit

Permalink
rust-cacheの導入: キャッシュのキーにmainを追加 (#334)
Browse files Browse the repository at this point in the history
* update: rust-cache: キャッシュのキーに`main`を追加
  • Loading branch information
YuukiToriyama authored Jul 5, 2024
1 parent e160368 commit 3cb036f
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/workflows/code-check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ jobs:
with:
cache-all-crates: true
shared-key: 'test-on-pr'
key: 'main'
save-if: ${{ github.ref == 'refs/heads/main' }} # mainブランチにコミットが追加された時のみキャッシュを保存する
cache-provider: 'github'
- name: Set up clippy
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/python-build-check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ jobs:
with:
cache-all-crates: true
shared-key: 'maturin-linux'
key: 'main'
save-if: ${{ github.ref == 'refs/heads/main' }} # mainブランチにコミットが追加された時のみキャッシュを保存する
cache-provider: 'github'
- uses: actions/setup-python@v5
Expand All @@ -38,6 +39,7 @@ jobs:
with:
cache-all-crates: true
shared-key: 'maturin-windows'
key: 'main'
save-if: ${{ github.ref == 'refs/heads/main' }} # mainブランチにコミットが追加された時のみキャッシュを保存する
cache-provider: 'github'
- uses: actions/setup-python@v5
Expand All @@ -59,6 +61,7 @@ jobs:
with:
cache-all-crates: true
shared-key: 'maturin-macos'
key: 'main'
save-if: ${{ github.ref == 'refs/heads/main' }} # mainブランチにコミットが追加された時のみキャッシュを保存する
cache-provider: 'github'
- uses: actions/setup-python@v5
Expand All @@ -79,6 +82,7 @@ jobs:
with:
cache-all-crates: true
shared-key: 'maturin-sdist'
key: 'main'
save-if: ${{ github.ref == 'refs/heads/main' }} # mainブランチにコミットが追加された時のみキャッシュを保存する
cache-provider: 'github'
- name: Build sdist
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/wasm-pack-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ jobs:
with:
cache-all-crates: true
shared-key: 'wasm-pack'
key: 'main'
save-if: ${{ github.ref == 'refs/heads/main' }} # mainブランチにコミットが追加された時のみキャッシュを保存する
cache-provider: 'github'
- name: Install wasm-pack
Expand Down

0 comments on commit 3cb036f

Please sign in to comment.