Compare commits

..

1 Commits

Author SHA1 Message Date
91d3aa4956 Update actions/core for releases/v2 (#466) 2023-03-28 12:09:52 +02:00
15 changed files with 42652 additions and 45368 deletions

5
.github/workflows/build.yml vendored Normal file → Executable file
View File

@ -20,11 +20,10 @@ jobs:
os: [ubuntu-latest, windows-latest, macos-latest]
steps:
- uses: actions/checkout@v2
- name: Setup Node.JS 16
- name: Setup Node.JS 12
uses: actions/setup-node@v2
with:
node-version: 16.x
cache: npm
node-version: 12.x
- run: npm ci
- run: npm run build
- run: npm run format-check

View File

@ -23,10 +23,10 @@ jobs:
steps:
- uses: actions/checkout@v2
- name: Set Node.js 16.x
- name: Set Node.js 12.x
uses: actions/setup-node@v1
with:
node-version: 16.x
node-version: 12.x
- name: Install dependencies
run: npm ci

View File

@ -19,7 +19,7 @@ jobs:
- name: Install licensed
run: |
cd $RUNNER_TEMP
curl -Lfs -o licensed.tar.gz https://github.com/github/licensed/releases/download/3.4.4/licensed-3.4.4-linux-x64.tar.gz
curl -Lfs -o licensed.tar.gz https://github.com/github/licensed/releases/download/3.3.1/licensed-3.3.1-linux-x64.tar.gz
sudo tar -xzf licensed.tar.gz
sudo mv licensed /usr/local/bin/licensed
- run: licensed status

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -66,11 +66,7 @@ Currently, the following distributions are supported:
**NOTE:** Adopt OpenJDK got moved to Eclipse Temurin and won't be updated anymore. It is highly recommended to migrate workflows from `adopt` to `temurin` to keep receiving software and security updates. See more details in the [Good-bye AdoptOpenJDK post](https://blog.adoptopenjdk.net/2021/08/goodbye-adoptopenjdk-hello-adoptium/).
### Caching packages dependencies
The action has a built-in functionality for caching and restoring dependencies. It uses [actions/cache](https://github.com/actions/cache) under hood for caching dependencies but requires less configuration settings. Supported package managers are gradle and maven. The format of the used cache key is `setup-java-${{ platform }}-${{ packageManager }}-${{ fileHash }}`, where the hash is based on the following files:
- gradle: `**/*.gradle*`, `**/gradle-wrapper.properties`
- maven: `**/pom.xml`
The cache input is optional, and caching is turned off by default.
The action has a built-in functionality for caching and restoring dependencies. It uses [actions/cache](https://github.com/actions/cache) under hood for caching dependencies but requires less configuration settings. Supported package managers are gradle and maven. The cache input is optional, and caching is turned off by default.
#### Caching gradle dependencies
```yaml

View File

@ -139,6 +139,7 @@ describe('findPackageForDownload', () => {
packageType: 'jdk',
checkLatest: false
});
distribution['getAvailableVersions'] = async () => manifestData;
await expect(
distribution['findPackageForDownload'](distribution['version'])
).rejects.toThrowError(/Could not find satisfied version for semver */);

View File

@ -67,6 +67,6 @@ outputs:
path:
description: 'Path to where the java environment has been installed (same as $JAVA_HOME)'
runs:
using: 'node16'
using: 'node12'
main: 'dist/setup/index.js'
post: 'dist/cleanup/index.js'

2513
dist/cleanup/index.js vendored

File diff suppressed because it is too large Load Diff

78775
dist/setup/index.js vendored

File diff suppressed because one or more lines are too long

6702
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -25,7 +25,7 @@
"license": "MIT",
"dependencies": {
"@actions/cache": "^1.0.8",
"@actions/core": "^1.2.6",
"@actions/core": "^1.10.0",
"@actions/exec": "^1.0.4",
"@actions/glob": "^0.2.0",
"@actions/http-client": "^1.0.11",
@ -36,7 +36,7 @@
},
"devDependencies": {
"@types/jest": "^27.0.2",
"@types/node": "^16.11.25",
"@types/node": "^12.19.13",
"@types/semver": "^7.3.4",
"@zeit/ncc": "^0.20.5",
"jest": "^27.2.5",
@ -44,5 +44,11 @@
"prettier": "^1.19.1",
"ts-jest": "^27.0.5",
"typescript": "^4.2.3"
},
"husky": {
"skipCI": true,
"hooks": {
"pre-commit": "npm run build && npm run format"
}
}
}