mirror of
https://github.com/actions/setup-java.git
synced 2025-03-13 09:37:03 +00:00
Merge branch 'main' into v-mshaganov/test-java
This commit is contained in:
commit
f8c7e8138b
11 changed files with 77 additions and 6330 deletions
3
.github/workflows/build.yml
vendored
3
.github/workflows/build.yml
vendored
|
@ -28,6 +28,3 @@ jobs:
|
|||
- run: npm run build
|
||||
- run: npm run format-check
|
||||
- run: npm test
|
||||
- name: Verify no unstaged changes
|
||||
if: runner.os != 'windows'
|
||||
run: bash __tests__/verify-no-unstaged-changes.sh
|
||||
|
|
51
.github/workflows/check-dist.yml
vendored
Normal file
51
.github/workflows/check-dist.yml
vendored
Normal file
|
@ -0,0 +1,51 @@
|
|||
# `dist/index.js` is a special file in Actions.
|
||||
# When you reference an action with `uses:` in a workflow,
|
||||
# `index.js` is the code that will run.
|
||||
# For our project, we generate this file through a build process from other source files.
|
||||
# We need to make sure the checked-in `index.js` actually matches what we expect it to be.
|
||||
name: Check dist/
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
paths-ignore:
|
||||
- '**.md'
|
||||
pull_request:
|
||||
paths-ignore:
|
||||
- '**.md'
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
check-dist:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Set Node.js 12.x
|
||||
uses: actions/setup-node@v1
|
||||
with:
|
||||
node-version: 12.x
|
||||
|
||||
- name: Install dependencies
|
||||
run: npm ci
|
||||
|
||||
- name: Rebuild the dist/ directory
|
||||
run: npm run build
|
||||
|
||||
- name: Compare the expected and actual dist/ directories
|
||||
run: |
|
||||
if [ "$(git diff --ignore-space-at-eol dist/ | wc -l)" -gt "0" ]; then
|
||||
echo "Detected uncommitted changes after build. See status below:"
|
||||
git diff
|
||||
exit 1
|
||||
fi
|
||||
id: diff
|
||||
|
||||
# If index.js was different than expected, upload the expected version as an artifact
|
||||
- uses: actions/upload-artifact@v2
|
||||
if: ${{ failure() && steps.diff.conclusion == 'failure' }}
|
||||
with:
|
||||
name: dist
|
||||
path: dist/
|
8
.github/workflows/licensed.yml
vendored
8
.github/workflows/licensed.yml
vendored
|
@ -1,8 +1,12 @@
|
|||
name: Licensed
|
||||
|
||||
on:
|
||||
push: {branches: main}
|
||||
pull_request: {branches: main}
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
pull_request:
|
||||
branches:
|
||||
- main
|
||||
|
||||
jobs:
|
||||
test:
|
||||
|
|
2
.licenses/npm/@actions/http-client.dep.yml
generated
2
.licenses/npm/@actions/http-client.dep.yml
generated
|
@ -1,6 +1,6 @@
|
|||
---
|
||||
name: "@actions/http-client"
|
||||
version: 1.0.9
|
||||
version: 1.0.11
|
||||
type: npm
|
||||
summary: Actions Http Client
|
||||
homepage: https://github.com/actions/http-client#readme
|
||||
|
|
|
@ -75,7 +75,7 @@ steps:
|
|||
distribution: 'temurin'
|
||||
java-version: '11'
|
||||
cache: 'gradle'
|
||||
- run: ./gradlew build
|
||||
- run: ./gradlew build --no-daemon
|
||||
```
|
||||
|
||||
#### Caching maven dependencies
|
||||
|
|
|
@ -1,17 +0,0 @@
|
|||
#!/bin/bash
|
||||
|
||||
if [[ "$(git status --porcelain)" != "" ]]; then
|
||||
echo ----------------------------------------
|
||||
echo git status
|
||||
echo ----------------------------------------
|
||||
git status
|
||||
echo ----------------------------------------
|
||||
echo git diff
|
||||
echo ----------------------------------------
|
||||
git diff
|
||||
echo ----------------------------------------
|
||||
echo Troubleshooting
|
||||
echo ----------------------------------------
|
||||
echo "::error::Unstaged changes detected. Locally try running: git clean -ffdx && npm ci && npm run pre-checkin"
|
||||
exit 1
|
||||
fi
|
7
dist/cleanup/index.js
vendored
7
dist/cleanup/index.js
vendored
|
@ -49663,7 +49663,9 @@ class HttpClient {
|
|||
maxSockets: maxSockets,
|
||||
keepAlive: this._keepAlive,
|
||||
proxy: {
|
||||
proxyAuth: `${proxyUrl.username}:${proxyUrl.password}`,
|
||||
...((proxyUrl.username || proxyUrl.password) && {
|
||||
proxyAuth: `${proxyUrl.username}:${proxyUrl.password}`
|
||||
}),
|
||||
host: proxyUrl.hostname,
|
||||
port: proxyUrl.port
|
||||
}
|
||||
|
@ -63235,10 +63237,9 @@ function importKey(privateKey) {
|
|||
exports.importKey = importKey;
|
||||
function deleteKey(keyFingerprint) {
|
||||
return __awaiter(this, void 0, void 0, function* () {
|
||||
yield exec.exec('gpg', ['--batch', '--yes', '--delete-secret-keys', keyFingerprint], {
|
||||
yield exec.exec('gpg', ['--batch', '--yes', '--delete-secret-and-public-key', keyFingerprint], {
|
||||
silent: true
|
||||
});
|
||||
yield exec.exec('gpg', ['--batch', '--yes', '--delete-keys', keyFingerprint], { silent: true });
|
||||
});
|
||||
}
|
||||
exports.deleteKey = deleteKey;
|
||||
|
|
7
dist/setup/index.js
vendored
7
dist/setup/index.js
vendored
|
@ -39653,7 +39653,9 @@ class HttpClient {
|
|||
maxSockets: maxSockets,
|
||||
keepAlive: this._keepAlive,
|
||||
proxy: {
|
||||
proxyAuth: `${proxyUrl.username}:${proxyUrl.password}`,
|
||||
...((proxyUrl.username || proxyUrl.password) && {
|
||||
proxyAuth: `${proxyUrl.username}:${proxyUrl.password}`
|
||||
}),
|
||||
host: proxyUrl.hostname,
|
||||
port: proxyUrl.port
|
||||
}
|
||||
|
@ -94687,10 +94689,9 @@ function importKey(privateKey) {
|
|||
exports.importKey = importKey;
|
||||
function deleteKey(keyFingerprint) {
|
||||
return __awaiter(this, void 0, void 0, function* () {
|
||||
yield exec.exec('gpg', ['--batch', '--yes', '--delete-secret-keys', keyFingerprint], {
|
||||
yield exec.exec('gpg', ['--batch', '--yes', '--delete-secret-and-public-key', keyFingerprint], {
|
||||
silent: true
|
||||
});
|
||||
yield exec.exec('gpg', ['--batch', '--yes', '--delete-keys', keyFingerprint], { silent: true });
|
||||
});
|
||||
}
|
||||
exports.deleteKey = deleteKey;
|
||||
|
|
6301
package-lock.json
generated
6301
package-lock.json
generated
File diff suppressed because it is too large
Load diff
|
@ -28,7 +28,7 @@
|
|||
"@actions/core": "^1.2.6",
|
||||
"@actions/exec": "^1.0.4",
|
||||
"@actions/glob": "^0.2.0",
|
||||
"@actions/http-client": "^1.0.9",
|
||||
"@actions/http-client": "^1.0.11",
|
||||
"@actions/io": "^1.0.2",
|
||||
"@actions/tool-cache": "^1.6.1",
|
||||
"semver": "^7.3.4",
|
||||
|
|
|
@ -39,8 +39,7 @@ export async function importKey(privateKey: string) {
|
|||
}
|
||||
|
||||
export async function deleteKey(keyFingerprint: string) {
|
||||
await exec.exec('gpg', ['--batch', '--yes', '--delete-secret-keys', keyFingerprint], {
|
||||
await exec.exec('gpg', ['--batch', '--yes', '--delete-secret-and-public-key', keyFingerprint], {
|
||||
silent: true
|
||||
});
|
||||
await exec.exec('gpg', ['--batch', '--yes', '--delete-keys', keyFingerprint], { silent: true });
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue