Merge pull request #156 from gradle/test-macos

Fix detection of Gradle User Home on macOS runners
This commit is contained in:
Daz DeBoer 2022-02-03 10:08:11 -07:00 committed by GitHub
commit 937999e9cc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
16 changed files with 39 additions and 41 deletions

View File

@ -13,7 +13,7 @@ jobs:
action-inputs:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources

View File

@ -14,7 +14,7 @@ jobs:
seed-build:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources
@ -38,7 +38,7 @@ jobs:
needs: seed-build
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources
@ -61,7 +61,7 @@ jobs:
cache-disabled:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources
@ -108,7 +108,7 @@ jobs:
GRADLE_BUILD_ACTION_CACHE_KEY_PREFIX: ${{github.workflow}}#${{github.run_number}}:${{github.run_attempt}}-write-only-
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources
@ -127,7 +127,7 @@ jobs:
needs: seed-build-write-only
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources

View File

@ -17,7 +17,7 @@ jobs:
GRADLE_BUILD_ACTION_CACHE_KEY_PREFIX: ${{github.workflow}}#${{github.run_number}}:${{github.run_attempt}}-groovy-
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources
@ -34,7 +34,7 @@ jobs:
needs: seed-build-groovy
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources
@ -56,7 +56,7 @@ jobs:
needs: seed-build-groovy
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources
@ -76,7 +76,7 @@ jobs:
GRADLE_BUILD_ACTION_CACHE_KEY_PREFIX: ${{github.workflow}}#${{github.run_number}}:${{github.run_attempt}}-kotlin-
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources
@ -93,7 +93,7 @@ jobs:
needs: seed-build-kotlin
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources
@ -111,7 +111,7 @@ jobs:
needs: modify-build-kotlin
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources

View File

@ -13,7 +13,7 @@ jobs:
seed-build:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources
@ -29,7 +29,7 @@ jobs:
needs: seed-build
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources
@ -47,7 +47,7 @@ jobs:
needs: seed-build
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources
@ -65,7 +65,7 @@ jobs:
needs: seed-build
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources

View File

@ -13,7 +13,7 @@ jobs:
seed-build:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources
@ -29,7 +29,7 @@ jobs:
needs: seed-build
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources

View File

@ -13,7 +13,7 @@ jobs:
seed-build:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources
@ -29,7 +29,7 @@ jobs:
needs: seed-build
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources

View File

@ -15,7 +15,7 @@ jobs:
gradle-execution:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
include:
- os: windows-latest
script-suffix: '.bat'
@ -46,7 +46,7 @@ jobs:
strategy:
matrix:
gradle: [7.3, 6.9, 5.6.4, 4.10.3]
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
include:
- gradle: 5.6.4
build-root-suffix: -gradle-5

View File

@ -16,7 +16,7 @@ jobs:
seed-build:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources
@ -32,7 +32,7 @@ jobs:
needs: seed-build
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources
@ -50,7 +50,7 @@ jobs:
needs: seed-build
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources

View File

@ -15,7 +15,7 @@ jobs:
provision-gradle:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
include:
- os: windows-latest
script-suffix: '.bat'
@ -49,7 +49,7 @@ jobs:
strategy:
matrix:
gradle: [7.3, 6.9, 5.6.4, 4.10.3]
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
include:
- gradle: 5.6.4
build-root-suffix: -gradle-5

View File

@ -14,7 +14,7 @@ jobs:
seed-build:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources
@ -29,7 +29,7 @@ jobs:
needs: seed-build
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources

View File

@ -14,7 +14,7 @@ jobs:
seed-build:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources
@ -29,7 +29,7 @@ jobs:
needs: seed-build
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources

2
dist/main/index.js vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

2
dist/post/index.js vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -102,13 +102,11 @@ export class GradleStateCache {
}
cacheOutputExists(): boolean {
const paths = this.getCachePath()
for (const p of paths) {
if (fs.existsSync(p)) {
cacheDebug(`Cache output exists at ${p}`)
const cachesDir = path.resolve(this.gradleUserHome, 'caches')
if (fs.existsSync(cachesDir)) {
cacheDebug(`Cache output exists at ${cachesDir}`)
return true
}
}
return false
}