mirror of
https://github.com/gradle/gradle-build-action.git
synced 2024-12-27 16:36:18 +08:00
Merge branch 'master' into releases/v1
This commit is contained in:
commit
e220e54c83
12
.github/workflows/dev.yml
vendored
12
.github/workflows/dev.yml
vendored
@ -6,7 +6,10 @@ on:
|
||||
|
||||
jobs:
|
||||
check:
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
matrix:
|
||||
os: [ubuntu-latest, macos-latest, windows-latest]
|
||||
runs-on: ${{ matrix.os }}
|
||||
steps:
|
||||
- name: Checkout sources
|
||||
uses: actions/checkout@v2
|
||||
@ -26,10 +29,3 @@ jobs:
|
||||
gradle-version: 6.5
|
||||
build-root-directory: __tests__/data/basic
|
||||
arguments: help
|
||||
- name: Check for uncommitted changes
|
||||
# Ensure no changes, but ignore node_modules dir since dev/fresh ci deps installed.
|
||||
run: |
|
||||
git diff --exit-code --stat -- . ':!node_modules' \
|
||||
|| (echo "##[error] found changed files after build. please 'npm run all'" \
|
||||
"and check in all changes" \
|
||||
&& exit 1)
|
||||
|
12
.github/workflows/prod.yml
vendored
12
.github/workflows/prod.yml
vendored
@ -9,7 +9,10 @@ on:
|
||||
|
||||
jobs:
|
||||
check:
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
matrix:
|
||||
os: [ubuntu-latest, macos-latest, windows-latest]
|
||||
runs-on: ${{ matrix.os }}
|
||||
steps:
|
||||
- name: Checkout sources
|
||||
uses: actions/checkout@v2
|
||||
@ -25,10 +28,3 @@ jobs:
|
||||
gradle-version: 6.5
|
||||
build-root-directory: __tests__/data/basic
|
||||
arguments: help
|
||||
- name: Check for uncommitted changes
|
||||
# Ensure no changes, but ignore node_modules dir since dev/fresh ci deps installed.
|
||||
run: |
|
||||
git diff --exit-code --stat -- . ':!node_modules' \
|
||||
|| (echo "##[error] found changed files after build. please 'npm run all'" \
|
||||
"and check in all changes" \
|
||||
&& exit 1)
|
||||
|
2
dist/main/index.js
vendored
2
dist/main/index.js
vendored
File diff suppressed because one or more lines are too long
2
dist/post/index.js
vendored
2
dist/post/index.js
vendored
File diff suppressed because one or more lines are too long
@ -2,6 +2,7 @@ import * as core from '@actions/core'
|
||||
import * as cache from '@actions/cache'
|
||||
import * as path from 'path'
|
||||
import * as fs from 'fs'
|
||||
import * as os from 'os'
|
||||
|
||||
const WRAPPER_CACHE_KEY = 'WRAPPER_CACHE_KEY'
|
||||
const WRAPPER_CACHE_PATH = 'WRAPPER_CACHE_PATH'
|
||||
@ -20,7 +21,7 @@ export async function restoreCachedWrapperDist(
|
||||
|
||||
const wrapperCacheKey = `wrapper-${wrapperSlug}`
|
||||
const wrapperCachePath = path.join(
|
||||
process.env.HOME!,
|
||||
os.homedir(),
|
||||
`.gradle/wrapper/dists/gradle-${wrapperSlug}`
|
||||
)
|
||||
|
||||
|
@ -1,4 +1,5 @@
|
||||
import * as fs from 'fs'
|
||||
import * as os from 'os'
|
||||
import * as path from 'path'
|
||||
import * as httpm from 'typed-rest-client/HttpClient'
|
||||
import * as unzip from 'unzipper'
|
||||
@ -93,7 +94,7 @@ async function provisionGradle(version: string, url: string): Promise<string> {
|
||||
return cachedExecutable
|
||||
}
|
||||
|
||||
const home = process.env['HOME'] || ''
|
||||
const home = os.homedir()
|
||||
const tmpdir = path.join(home, 'gradle-provision-tmpdir')
|
||||
const downloadsDir = path.join(tmpdir, 'downloads')
|
||||
const installsDir = path.join(tmpdir, 'installs')
|
||||
|
Loading…
x
Reference in New Issue
Block a user