diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index a8d742cf..f407fbf8 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -20,6 +20,9 @@ jobs: distribution: 'temurin' java-version: 17 - uses: gradle/gradle-build-action@v2 + with: + # allow master and *-dev branches to write caches (default is only master/main) + cache-read-only: ${{ github.ref != 'refs/heads/master' && !(github.ref.endsWith('-dev') && github.ref.startsWith('refs/heads/')) }} # gradle-build-action doesn't support caching files in the project dir - uses: actions/cache@v3 with: