Skip to content

Commit 937fa9c

Browse files
committed
ci(dataverse): add permission to clear and save the cache
1 parent c582de2 commit 937fa9c

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

.github/workflows/maven_unit_test.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,14 +36,16 @@ jobs:
3636
# status: "Experimental"
3737
continue-on-error: ${{ matrix.experimental }}
3838
runs-on: ubuntu-latest
39+
permissions:
40+
actions: write # necessary to clear and save the Maven cache
3941
steps:
4042
- uses: actions/checkout@v3
4143
- name: Set up JDK ${{ matrix.jdk }}
4244
uses: actions/setup-java@v3
4345
with:
4446
java-version: ${{ matrix.jdk }}
4547
distribution: 'adopt'
46-
- name: Cache Maven packages
48+
- name: Restore Maven packages from cache
4749
id: restore-m2-cache
4850
uses: actions/cache/restore@v3
4951
with:
@@ -85,7 +87,7 @@ jobs:
8587
gh actions-cache delete ${{ steps.restore-m2-cache.outputs.cache-primary-key }} --confirm
8688
8789
# To cache built Maven submodules, summon the save to cache action
88-
- name: Save Maven packages in Cache
90+
- name: Save Maven packages to cache
8991
uses: actions/cache/save@v3
9092
if: always() # Try to save cache, will not fail if key still exists because clean failed
9193
with:

0 commit comments

Comments
 (0)