Skip to content

Commit de4f684

Browse files
authored
Merge pull request #260 from IanButterworth/ib/cache
use julia-actions/cache in CI
2 parents 43e0e9d + 0485197 commit de4f684

File tree

1 file changed

+8
-10
lines changed

1 file changed

+8
-10
lines changed

.github/workflows/CI.yml

+8-10
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,11 @@ concurrency:
1515
group: ${{ github.workflow }}-${{ github.ref }}
1616
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
1717

18+
# needed to allow julia-actions/cache to delete old caches that it has created
19+
permissions:
20+
actions: write
21+
contents: read
22+
1823
jobs:
1924
test:
2025
name: ${{ matrix.suite }} - Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }}
@@ -50,16 +55,7 @@ jobs:
5055
with:
5156
version: ${{ matrix.version }}
5257
arch: ${{ matrix.arch }}
53-
- uses: actions/cache@v3
54-
env:
55-
cache-name: cache-artifacts
56-
with:
57-
path: ~/.julia/artifacts
58-
key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }}
59-
restore-keys: |
60-
${{ runner.os }}-test-${{ env.cache-name }}-
61-
${{ runner.os }}-test-
62-
${{ runner.os }}-
58+
- uses: julia-actions/cache@v1
6359
- uses: julia-actions/julia-buildpkg@v1
6460
- name: "Setup environment"
6561
run: |
@@ -91,6 +87,7 @@ jobs:
9187
with:
9288
version: '1'
9389
arch: x64
90+
- uses: julia-actions/cache@v1
9491
- uses: julia-actions/julia-buildpkg@v1
9592
- uses: actions/download-artifact@v3
9693
- run: |
@@ -109,6 +106,7 @@ jobs:
109106
- uses: julia-actions/setup-julia@v1
110107
with:
111108
version: '1.6'
109+
- uses: julia-actions/cache@v1
112110
- run: |
113111
julia --project=docs -e '
114112
using Pkg

0 commit comments

Comments
 (0)