Merge branch 'actions:main' into issue725-ReadMeSupportedVersionSyntax

This commit is contained in:
christian 2025-09-04 14:28:45 +02:00 committed by GitHub
commit 855e2f2a2c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
48 changed files with 2831 additions and 485 deletions

View File

@ -16,4 +16,4 @@ jobs:
name: Basic validation
uses: actions/reusable-workflows/.github/workflows/basic-validation.yml@main
with:
node-version: '20.x'
node-version: '24.x'

View File

@ -16,4 +16,4 @@ jobs:
name: Check dist/
uses: actions/reusable-workflows/.github/workflows/check-dist.yml@main
with:
node-version: '20.x'
node-version: '24.x'

View File

@ -24,13 +24,13 @@ jobs:
os: [macos-latest, windows-latest, ubuntu-latest]
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: Run setup-java with the cache for gradle
uses: ./
id: setup-java
with:
distribution: 'adopt'
java-version: '11'
java-version: '17'
cache: gradle
cache-dependency-path: __tests__/cache/gradle1/*.gradle*
- name: Create files to cache
@ -51,7 +51,7 @@ jobs:
needs: gradle1-save
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: Run setup-java with the cache for gradle
uses: ./
id: setup-java
@ -76,7 +76,7 @@ jobs:
needs: gradle1-save
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: Run setup-java with the cache for gradle
uses: ./
id: setup-java

View File

@ -24,13 +24,13 @@ jobs:
os: [macos-13, windows-latest, ubuntu-latest]
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: Run setup-java with the cache for gradle
uses: ./
id: setup-java
with:
distribution: 'adopt'
java-version: '11'
java-version: '17'
cache: gradle
- name: Create files to cache
# Need to avoid using Gradle daemon to stabilize the save process on Windows
@ -50,7 +50,7 @@ jobs:
needs: gradle-save
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: Run setup-java with the cache for gradle
uses: ./
id: setup-java
@ -73,7 +73,7 @@ jobs:
os: [macos-13, windows-latest, ubuntu-latest]
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: Run setup-java with the cache for maven
uses: ./
id: setup-java
@ -97,7 +97,7 @@ jobs:
needs: maven-save
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: Run setup-java with the cache for maven
uses: ./
id: setup-java
@ -124,7 +124,7 @@ jobs:
os: [macos-13, windows-latest, ubuntu-22.04]
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: Run setup-java with the cache for sbt
uses: ./
id: setup-java
@ -174,7 +174,7 @@ jobs:
needs: sbt-save
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: Run setup-java with the cache for sbt
uses: ./
id: setup-java

View File

@ -21,7 +21,7 @@ jobs:
os: [macos-latest, windows-latest, ubuntu-latest]
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: Download Adopt OpenJDK file
run: |
if ($IsLinux) {
@ -58,7 +58,7 @@ jobs:
os: [macos-latest, windows-latest, ubuntu-latest]
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: Download Zulu OpenJDK file
run: |
if ($IsLinux) {
@ -95,7 +95,7 @@ jobs:
os: [macos-latest, windows-latest, ubuntu-latest]
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: Download Eclipse Temurin file
run: |
if ($IsLinux) {

View File

@ -25,7 +25,7 @@ jobs:
os: [macos-latest, windows-latest, ubuntu-latest]
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: setup-java
uses: ./
id: setup-java
@ -60,7 +60,7 @@ jobs:
os: [macos-latest, windows-latest, ubuntu-latest]
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: Create fake settings.xml
run: |
$xmlDirectory = Join-Path $HOME ".m2"
@ -96,7 +96,7 @@ jobs:
os: [macos-latest, windows-latest, ubuntu-latest]
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: Create fake settings.xml
run: |
$xmlDirectory = Join-Path $HOME ".m2"
@ -133,7 +133,7 @@ jobs:
os: [macos-latest, windows-latest, ubuntu-latest]
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: setup-java
uses: ./
id: setup-java

View File

@ -64,7 +64,7 @@ jobs:
version: '24-ea'
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: setup-java
uses: ./
id: setup-java
@ -114,7 +114,7 @@ jobs:
version: '17.0.7'
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: setup-java
uses: ./
id: setup-java
@ -149,7 +149,7 @@ jobs:
os: macos-latest
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: setup-java
uses: ./
id: setup-java
@ -185,7 +185,7 @@ jobs:
os: macos-latest
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: setup-java
uses: ./
id: setup-java
@ -224,7 +224,7 @@ jobs:
version: ['17-ea', '15.0.0-ea.14']
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: setup-java
uses: ./
id: setup-java
@ -246,7 +246,7 @@ jobs:
version: ['17-ea']
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: setup-java
uses: ./
id: setup-java
@ -268,7 +268,7 @@ jobs:
version: ['17-ea', '21-ea']
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: setup-java
uses: ./
id: setup-java
@ -355,7 +355,7 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: setup-java
uses: ./
id: setup-java
@ -383,7 +383,7 @@ jobs:
version: ['11']
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: setup-java
uses: ./
id: setup-java
@ -406,7 +406,7 @@ jobs:
java-version-file: ['.java-version', '.tool-versions']
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: Create .java-version file
shell: bash
run: echo "17" > .java-version
@ -435,7 +435,7 @@ jobs:
java-version-file: ['.java-version', '.tool-versions']
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: Create .java-version file
shell: bash
run: echo "11" > .java-version
@ -463,7 +463,7 @@ jobs:
java-version-file: ['.java-version', '.tool-versions']
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: Create .java-version file
shell: bash
run: echo "17.0.10" > .java-version
@ -491,7 +491,7 @@ jobs:
java-version-file: ['.java-version', '.tool-versions']
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: Create .java-version file
shell: bash
run: echo "openjdk64-17.0.10" > .java-version

View File

@ -15,7 +15,7 @@ jobs:
steps:
- name: Checking out
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: Publish
id: publish
uses: actions/publish-immutable-action@v0.0.4

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
.licenses/npm/dunder-proto.dep.yml generated Normal file

Binary file not shown.

BIN
.licenses/npm/es-define-property.dep.yml generated Normal file

Binary file not shown.

BIN
.licenses/npm/es-errors.dep.yml generated Normal file

Binary file not shown.

BIN
.licenses/npm/es-object-atoms.dep.yml generated Normal file

Binary file not shown.

BIN
.licenses/npm/es-set-tostringtag.dep.yml generated Normal file

Binary file not shown.

BIN
.licenses/npm/function-bind.dep.yml generated Normal file

Binary file not shown.

BIN
.licenses/npm/get-intrinsic.dep.yml generated Normal file

Binary file not shown.

BIN
.licenses/npm/get-proto.dep.yml generated Normal file

Binary file not shown.

BIN
.licenses/npm/gopd.dep.yml generated Normal file

Binary file not shown.

BIN
.licenses/npm/has-symbols.dep.yml generated Normal file

Binary file not shown.

BIN
.licenses/npm/has-tostringtag.dep.yml generated Normal file

Binary file not shown.

BIN
.licenses/npm/hasown.dep.yml generated Normal file

Binary file not shown.

BIN
.licenses/npm/math-intrinsics.dep.yml generated Normal file

Binary file not shown.

BIN
.licenses/npm/safe-buffer.dep.yml generated Normal file

Binary file not shown.

Binary file not shown.

View File

@ -23,6 +23,8 @@ This action allows you to work with Java and Scala projects.
- V2 supports custom distributions and provides support for Azul Zulu OpenJDK, Eclipse Temurin and AdoptOpenJDK out of the box. V1 supports only Azul Zulu OpenJDK.
- V2 requires you to specify distribution along with the version. V1 defaults to Azul Zulu OpenJDK, only version input is required. Follow [the migration guide](docs/switching-to-v2.md) to switch from V1 to V2.
For information about the latest releases, recent updates, and newly supported distributions, please refer to the `setup-java` [Releases](https://github.com/actions/setup-java/releases).
## Usage
- `java-version`: The Java version that is going to be set up. Takes a whole or [semver](#supported-version-syntax) Java version. If not specified, the action will expect `java-version-file` input to be specified.
@ -69,8 +71,8 @@ This action allows you to work with Java and Scala projects.
#### Eclipse Temurin
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: 'temurin' # See 'Supported distributions' for available options
java-version: '21'
@ -80,8 +82,8 @@ steps:
#### Azul Zulu OpenJDK
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: 'zulu' # See 'Supported distributions' for available options
java-version: '21'
@ -138,8 +140,8 @@ The cache input is optional, and caching is turned off by default.
#### Caching gradle dependencies
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: 'temurin'
java-version: '21'
@ -153,8 +155,8 @@ steps:
#### Caching maven dependencies
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: 'temurin'
java-version: '21'
@ -167,8 +169,8 @@ steps:
#### Caching sbt dependencies
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: 'temurin'
java-version: '21'
@ -187,8 +189,8 @@ Usually, cache gets downloaded in multiple segments of fixed sizes. Sometimes, a
env:
SEGMENT_DOWNLOAD_TIMEOUT_MINS: '5'
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: 'temurin'
java-version: '21'
@ -207,8 +209,8 @@ For Java distributions that are not cached on Hosted images, `check-latest` alwa
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: 'temurin'
java-version: '21'
@ -226,9 +228,9 @@ jobs:
java: [ '8', '11', '17', '21' ]
name: Java ${{ matrix.Java }} sample
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v5
- name: Setup java
uses: actions/setup-java@v4
uses: actions/setup-java@v5
with:
distribution: '<distribution>'
java-version: ${{ matrix.java }}
@ -241,7 +243,7 @@ All versions are added to the PATH. The last version will be used and available
```yaml
steps:
- uses: actions/setup-java@v4
- uses: actions/setup-java@v5
with:
distribution: '<distribution>'
java-version: |

View File

@ -191,7 +191,9 @@ describe('getAvailableVersions', () => {
])(
'defaults to os.arch(): %s mapped to distro arch: %s',
async (osArch: string, distroArch: string) => {
jest.spyOn(os, 'arch').mockReturnValue(osArch);
jest
.spyOn(os, 'arch')
.mockReturnValue(osArch as ReturnType<typeof os.arch>);
const installerOptions: JavaInstallerOptions = {
version: '17',

View File

@ -287,7 +287,7 @@ describe('setupJava', () => {
spyCoreSetOutput = jest.spyOn(core, 'setOutput');
spyCoreSetOutput.mockImplementation(() => undefined);
jest.spyOn(os, 'arch').mockReturnValue('x86');
jest.spyOn(os, 'arch').mockReturnValue('x86' as ReturnType<typeof os.arch>);
});
afterEach(() => {

View File

@ -203,28 +203,27 @@ describe('getAvailableVersions', () => {
});
it.each([
['arm64', 'aarch64'],
['amd64', 'x64']
['amd64', 'x64'],
['arm64', 'aarch64']
])(
'defaults to os.arch(): %s mapped to distro arch: %s',
async (osArch: string, distroArch: string) => {
jest.spyOn(os, 'arch').mockReturnValue(osArch);
jest
.spyOn(os, 'arch')
.mockReturnValue(osArch as ReturnType<typeof os.arch>);
const version = '17';
const installerOptions: JavaInstallerOptions = {
version,
const distribution = new CorrettoDistribution({
version: '17',
architecture: '', // to get default value
packageType: 'jdk',
checkLatest: false
};
const distribution = new CorrettoDistribution(installerOptions);
});
mockPlatform(distribution, 'macos');
const expectedLink = `https://corretto.aws/downloads/resources/17.0.2.8.1/amazon-corretto-17.0.2.8.1-macosx-${distroArch}.tar.gz`;
const availableVersion = await distribution['findPackageForDownload'](
version
'17'
);
expect(availableVersion).not.toBeNull();
expect(availableVersion.url).toBe(expectedLink);

View File

@ -98,31 +98,35 @@ describe('findPackageForDownload', () => {
});
it.each([
['amd64', 'x64'],
['arm64', 'aarch64']
['amd64', ['x64', 'amd64']],
['arm64', ['aarch64', 'arm64']]
])(
'defaults to os.arch(): %s mapped to distro arch: %s',
async (osArch: string, distroArch: string) => {
jest.spyOn(os, 'arch').mockReturnValue(osArch);
jest.spyOn(os, 'platform').mockReturnValue('linux');
async (osArch: string, distroArchs: string[]) => {
jest
.spyOn(os, 'arch')
.mockReturnValue(osArch as ReturnType<typeof os.arch>);
const version = '21';
const distro = new GraalVMDistribution({
version,
const distribution = new GraalVMDistribution({
version: '21',
architecture: '', // to get default value
packageType: 'jdk',
checkLatest: false
});
const osType = distribution.getPlatform();
if (osType === 'windows' && distroArch == 'aarch64') {
if (osType === 'windows' && distroArchs.includes('aarch64')) {
return; // skip, aarch64 is not available for Windows
}
const archiveType = getDownloadArchiveExtension();
const result = await distro['findPackageForDownload'](version);
const expectedUrl = `https://download.oracle.com/graalvm/21/latest/graalvm-jdk-21_${osType}-${distroArch}_bin.${archiveType}`;
const result = await distribution['findPackageForDownload']('21');
expect(result.url).toBe(expectedUrl);
const expectedUrls = distroArchs.map(
distroArch =>
`https://download.oracle.com/graalvm/21/latest/graalvm-jdk-21_${osType}-${distroArch}_bin.${archiveType}`
);
expect(expectedUrls).toContain(result.url);
}
);

View File

@ -105,9 +105,11 @@ describe('getAvailableVersions', () => {
])(
'defaults to os.arch(): %s mapped to distro arch: %s',
async (osArch: string, distroArch: DistroArch) => {
jest.spyOn(os, 'arch').mockReturnValue(osArch);
jest
.spyOn(os, 'arch')
.mockReturnValue(osArch as ReturnType<typeof os.arch>);
const distribution = new LibericaDistributions({
const distributions = new LibericaDistributions({
version: '17',
architecture: '', // to get default value
packageType: 'jdk',
@ -117,11 +119,11 @@ describe('getAvailableVersions', () => {
const additionalParams =
'&installation-type=archive&fields=downloadUrl%2Cversion%2CfeatureVersion%2CinterimVersion%2C' +
'updateVersion%2CbuildVersion';
distribution['getPlatformOption'] = () => 'macos';
distributions['getPlatformOption'] = () => 'macos';
const buildUrl = `https://api.bell-sw.com/v1/liberica/releases?os=macos&bundle-type=jdk&bitness=${distroArch.bitness}&arch=${distroArch.arch}&build-type=all${additionalParams}`;
await distribution['getAvailableVersions']();
await distributions['getAvailableVersions']();
expect(spyHttpClient.mock.calls).toHaveLength(1);
expect(spyHttpClient.mock.calls[0][0]).toBe(buildUrl);

View File

@ -105,7 +105,9 @@ describe('getAvailableVersions', () => {
])(
'defaults to os.arch(): %s mapped to distro arch: %s',
async (osArch: string, distroArch: DistroArch) => {
jest.spyOn(os, 'arch').mockReturnValue(osArch);
jest
.spyOn(os, 'arch')
.mockReturnValue(osArch as ReturnType<typeof os.arch>);
const distribution = new LibericaDistributions({
version: '17',

View File

@ -105,7 +105,9 @@ describe('getAvailableVersions', () => {
])(
'defaults to os.arch(): %s mapped to distro arch: %s',
async (osArch: string, distroArch: DistroArch) => {
jest.spyOn(os, 'arch').mockReturnValue(osArch);
jest
.spyOn(os, 'arch')
.mockReturnValue(osArch as ReturnType<typeof os.arch>);
const distribution = new LibericaDistributions({
version: '17',

View File

@ -95,7 +95,9 @@ describe('findPackageForDownload', () => {
])(
'defaults to os.arch(): %s mapped to distro arch: %s',
async (osArch: string, distroArch: string) => {
jest.spyOn(os, 'arch').mockReturnValue(osArch);
jest
.spyOn(os, 'arch')
.mockReturnValue(osArch as ReturnType<typeof os.arch>);
jest.spyOn(os, 'platform').mockReturnValue('darwin');
const version = '17';
@ -119,7 +121,9 @@ describe('findPackageForDownload', () => {
])(
'defaults to os.arch(): %s mapped to distro arch: %s',
async (osArch: string, distroArch: string) => {
jest.spyOn(os, 'arch').mockReturnValue(osArch);
jest
.spyOn(os, 'arch')
.mockReturnValue(osArch as ReturnType<typeof os.arch>);
jest.spyOn(os, 'platform').mockReturnValue('linux');
const version = '17';
@ -143,7 +147,9 @@ describe('findPackageForDownload', () => {
])(
'defaults to os.arch(): %s mapped to distro arch: %s',
async (osArch: string, distroArch: string) => {
jest.spyOn(os, 'arch').mockReturnValue(osArch);
jest
.spyOn(os, 'arch')
.mockReturnValue(osArch as ReturnType<typeof os.arch>);
jest.spyOn(os, 'platform').mockReturnValue('win32');
const version = '17';

View File

@ -95,7 +95,9 @@ describe('findPackageForDownload', () => {
])(
'defaults to os.arch(): %s mapped to distro arch: %s',
async (osArch: string, distroArch: string) => {
jest.spyOn(os, 'arch').mockReturnValue(osArch);
jest
.spyOn(os, 'arch')
.mockReturnValue(osArch as ReturnType<typeof os.arch>);
jest.spyOn(os, 'platform').mockReturnValue('linux');
const version = '18';

View File

@ -147,7 +147,9 @@ describe('getAvailableVersions', () => {
])(
'defaults to os.arch(): %s mapped to distro arch: %s',
async (osArch: string, distroArch: string) => {
jest.spyOn(os, 'arch').mockReturnValue(distroArch);
jest
.spyOn(os, 'arch')
.mockReturnValue(osArch as ReturnType<typeof os.arch>);
const installerOptions: JavaInstallerOptions = {
version: '17',

View File

@ -1,5 +1,4 @@
import {HttpClient} from '@actions/http-client';
import * as semver from 'semver';
import {ZuluDistribution} from '../../src/distributions/zulu/installer';
import {IZuluVersions} from '../../src/distributions/zulu/models';
import * as utils from '../../src/util';
@ -126,7 +125,9 @@ describe('getAvailableVersions', () => {
])(
'defaults to os.arch(): %s mapped to distro arch: %s',
async (osArch: string, distroArch: DistroArch) => {
jest.spyOn(os, 'arch').mockReturnValue(osArch);
jest
.spyOn(os, 'arch')
.mockReturnValue(osArch as ReturnType<typeof os.arch>);
const distribution = new ZuluDistribution({
version: '17',

View File

@ -126,7 +126,9 @@ describe('getAvailableVersions', () => {
])(
'defaults to os.arch(): %s mapped to distro arch: %s',
async (osArch: string, distroArch: DistroArch) => {
jest.spyOn(os, 'arch').mockReturnValue(osArch);
jest
.spyOn(os, 'arch')
.mockReturnValue(osArch as ReturnType<typeof os.arch>);
const distribution = new ZuluDistribution({
version: '17',
@ -135,7 +137,9 @@ describe('getAvailableVersions', () => {
checkLatest: false
});
distribution['getPlatformOption'] = () => 'linux';
const buildUrl = `https://api.azul.com/zulu/download/community/v1.0/bundles/?os=linux&ext=zip&bundle_type=jdk&javafx=false&arch=${distroArch.arch}&hw_bitness=${distroArch.bitness}&release_status=ga`;
// Override extension for linux default arch case to match util behavior
spyUtilGetDownloadArchiveExtension.mockReturnValue('tar.gz');
const buildUrl = `https://api.azul.com/zulu/download/community/v1.0/bundles/?os=linux&ext=tar.gz&bundle_type=jdk&javafx=false&arch=${distroArch.arch}&hw_bitness=${distroArch.bitness}&release_status=ga`;
await distribution['getAvailableVersions']();

View File

@ -126,7 +126,9 @@ describe('getAvailableVersions', () => {
])(
'defaults to os.arch(): %s mapped to distro arch: %s',
async (osArch: string, distroArch: DistroArch) => {
jest.spyOn(os, 'arch').mockReturnValue(osArch);
jest
.spyOn(os, 'arch')
.mockReturnValue(osArch as ReturnType<typeof os.arch>);
const distribution = new ZuluDistribution({
version: '17',

View File

@ -81,6 +81,6 @@ outputs:
cache-hit:
description: 'A boolean value to indicate an exact match was found for the primary key'
runs:
using: 'node20'
using: 'node24'
main: 'dist/setup/index.js'
post: 'dist/cleanup/index.js'

1378
dist/cleanup/index.js vendored

File diff suppressed because it is too large Load Diff

1378
dist/setup/index.js vendored

File diff suppressed because it is too large Load Diff

View File

@ -31,8 +31,8 @@ Inputs `java-version` and `distribution` are mandatory and needs to be provided.
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: 'temurin'
java-version: '21'
@ -44,8 +44,8 @@ steps:
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: 'adopt-hotspot'
java-version: '11'
@ -56,8 +56,8 @@ steps:
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: 'zulu'
java-version: '21'
@ -69,8 +69,8 @@ steps:
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: 'liberica'
java-version: '21'
@ -82,8 +82,8 @@ steps:
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: 'microsoft'
java-version: '21'
@ -97,7 +97,7 @@ steps:
To get a higher rate limit, you can [generate a personal access token on github.com](https://github.com/settings/tokens/new) and pass it as the `token` input for the action:
```yaml
uses: actions/setup-java@v4
uses: actions/setup-java@v5
with:
token: ${{ secrets.GH_DOTCOM_TOKEN }}
distribution: 'microsoft'
@ -111,8 +111,8 @@ If the runner is not able to access github.com, any Java versions requested duri
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: 'corretto'
java-version: '21'
@ -124,8 +124,8 @@ steps:
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: 'oracle'
java-version: '21'
@ -137,8 +137,8 @@ steps:
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: 'dragonwell'
java-version: '8'
@ -149,8 +149,8 @@ steps:
**NOTE:** An OpenJDK release maintained and supported by SAP
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: 'sapmachine'
java-version: '21'
@ -162,8 +162,8 @@ steps:
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: 'graalvm'
java-version: '21'
@ -181,8 +181,8 @@ For example, `11.0.24` is not available but `11.0.16` is.
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: 'jetbrains'
java-version: '11'
@ -194,8 +194,8 @@ GitHub token to the action to increase the rate limit. Set the `GITHUB_TOKEN` en
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: 'jetbrains'
java-version: '17'
@ -219,8 +219,8 @@ The available package types are:
## Installing custom Java package type
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: '<distribution>'
java-version: '11'
@ -232,8 +232,8 @@ steps:
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: '<distribution>'
java-version: '11'
@ -249,7 +249,7 @@ steps:
- run: |
download_url="https://github.com/AdoptOpenJDK/openjdk11-binaries/releases/download/jdk-11.0.10%2B9/OpenJDK11U-jdk_x64_linux_hotspot_11.0.10_9.tar.gz"
wget -O $RUNNER_TEMP/java_package.tar.gz $download_url
- uses: actions/setup-java@v4
- uses: actions/setup-java@v5
with:
distribution: 'jdkfile'
jdkFile: ${{ runner.temp }}/java_package.tar.gz
@ -275,7 +275,7 @@ If your use-case requires a custom distribution (in the example, alpine-linux is
latest_semver_version=$(curl -sL $latest_jdk_json_url | jq -r 'version.semver')
echo "java_version=$latest_semver_version" >> "$GITHUB_OUTPUT"
- uses: actions/setup-java@v4
- uses: actions/setup-java@v5
with:
distribution: 'jdkfile'
jdkFile: ${{ runner.temp }}/java_package.tar.gz
@ -296,9 +296,9 @@ jobs:
java: [ '8', '11' ]
name: Java ${{ matrix.Java }} (${{ matrix.distribution }}) sample
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v5
- name: Setup java
uses: actions/setup-java@v4
uses: actions/setup-java@v5
with:
distribution: ${{ matrix.distribution }}
java-version: ${{ matrix.java }}
@ -316,9 +316,9 @@ jobs:
os: [ 'ubuntu-latest', 'macos-latest', 'windows-latest' ]
name: Java ${{ matrix.Java }} (${{ matrix.os }}) sample
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v5
- name: Setup java
uses: actions/setup-java@v4
uses: actions/setup-java@v5
with:
distribution: 'temurin'
java-version: ${{ matrix.java }}
@ -333,9 +333,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v5
- name: Set up JDK 11
uses: actions/setup-java@v4
uses: actions/setup-java@v5
with:
distribution: '<distribution>'
java-version: '11'
@ -349,7 +349,7 @@ jobs:
GITHUB_TOKEN: ${{ github.token }} # GITHUB_TOKEN is the default env for the password
- name: Set up Apache Maven Central
uses: actions/setup-java@v4
uses: actions/setup-java@v5
with: # running setup-java again overwrites the settings.xml
distribution: 'temurin'
java-version: '11'
@ -446,9 +446,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v5
- name: Set up JDK 11 for Shared Runner
uses: actions/setup-java@v4
uses: actions/setup-java@v5
with:
distribution: '<distribution>'
java-version: '11'
@ -472,10 +472,10 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v5
- name: Set up JDK 11
uses: actions/setup-java@v4
uses: actions/setup-java@v5
with:
distribution: '<distribution>'
java-version: '11'
@ -509,14 +509,14 @@ Subsequent calls to `setup-java` with distinct distribution and version paramete
```yaml
steps:
- uses: actions/setup-java@v4
- uses: actions/setup-java@v5
with:
distribution: '<distribution>'
java-version: |
8
11
- uses: actions/setup-java@v4
- uses: actions/setup-java@v5
with:
distribution: '<distribution>'
java-version: '15'
@ -528,7 +528,7 @@ The result is a Toolchain with entries for JDKs 8, 11 and 15. You can even combi
- run: |
download_url="https://example.com/java/jdk/6u45-b06/jdk-6u45-linux-x64.tar.gz"
wget -O $RUNNER_TEMP/java_package.tar.gz $download_url
- uses: actions/setup-java@v4
- uses: actions/setup-java@v5
with:
distribution: 'jdkfile'
jdkFile: ${{ runner.temp }}/java_package.tar.gz
@ -545,7 +545,7 @@ Each JDK provider will receive a default `vendor` using the `distribution` input
- run: |
download_url="https://example.com/java/jdk/6u45-b06/jdk-6u45-linux-x64.tar.gz"
wget -O $RUNNER_TEMP/java_package.tar.gz $download_url
- uses: actions/setup-java@v4
- uses: actions/setup-java@v5
with:
distribution: 'jdkfile'
jdkFile: ${{ runner.temp }}/java_package.tar.gz
@ -560,7 +560,7 @@ In case you install multiple versions of Java at once with multi-line `java-vers
```yaml
steps:
- uses: actions/setup-java@v4
- uses: actions/setup-java@v5
with:
distribution: '<distribution>'
java-version: |
@ -574,8 +574,8 @@ Each JDK provider will receive a default `id` based on the combination of `distr
```yaml
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
- uses: actions/checkout@v5
- uses: actions/setup-java@v5
with:
distribution: 'temurin'
java-version: '11'
@ -587,7 +587,7 @@ In case you install multiple versions of Java at once you can use the same synta
```yaml
steps:
- uses: actions/setup-java@v4
- uses: actions/setup-java@v5
with:
distribution: '<distribution>'
java-version: |

239
package-lock.json generated
View File

@ -1,12 +1,12 @@
{
"name": "setup-java",
"version": "4.0.0",
"version": "5.0.0",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "setup-java",
"version": "4.0.0",
"version": "5.0.0",
"license": "MIT",
"dependencies": {
"@actions/cache": "^4.0.3",
@ -21,7 +21,7 @@
},
"devDependencies": {
"@types/jest": "^29.5.14",
"@types/node": "^20.11.24",
"@types/node": "^24.1.0",
"@types/semver": "^7.5.8",
"@typescript-eslint/eslint-plugin": "^8.35.1",
"@typescript-eslint/parser": "^8.35.1",
@ -35,6 +35,9 @@
"prettier": "^2.8.4",
"ts-jest": "^29.3.0",
"typescript": "^5.3.3"
},
"engines": {
"node": ">=24.0.0"
}
},
"node_modules/@aashutoshrathi/word-wrap": {
@ -206,12 +209,14 @@
}
},
"node_modules/@azure/core-http/node_modules/form-data": {
"version": "4.0.0",
"resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.0.tgz",
"integrity": "sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==",
"version": "4.0.4",
"resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.4.tgz",
"integrity": "sha512-KrGhL9Q4zjj0kiUt5OO4Mr/A/jlI2jDYs5eHBpYHPcBEVSiipAvn2Ko2HnPe20rmcuuvMHNdZFp+4IlGTMF0Ow==",
"dependencies": {
"asynckit": "^0.4.0",
"combined-stream": "^1.0.8",
"es-set-tostringtag": "^2.1.0",
"hasown": "^2.0.2",
"mime-types": "^2.1.12"
},
"engines": {
@ -1642,11 +1647,12 @@
}
},
"node_modules/@types/node": {
"version": "20.11.24",
"resolved": "https://registry.npmjs.org/@types/node/-/node-20.11.24.tgz",
"integrity": "sha512-Kza43ewS3xoLgCEpQrsT+xRo/EJej1y0kVYGiLFE1NEODXGzTfwiC6tXTLMQskn1X4/Rjlh0MQUvx9W+L9long==",
"version": "24.1.0",
"resolved": "https://registry.npmjs.org/@types/node/-/node-24.1.0.tgz",
"integrity": "sha512-ut5FthK5moxFKH2T1CUOC6ctR67rQRvvHdFLCD2Ql6KXmMuCrjsSsRI9UsLCm9M18BMwClv4pn327UvB7eeO1w==",
"license": "MIT",
"dependencies": {
"undici-types": "~5.26.4"
"undici-types": "~7.8.0"
}
},
"node_modules/@types/node-fetch": {
@ -1659,12 +1665,14 @@
}
},
"node_modules/@types/node-fetch/node_modules/form-data": {
"version": "4.0.0",
"resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.0.tgz",
"integrity": "sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==",
"version": "4.0.4",
"resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.4.tgz",
"integrity": "sha512-KrGhL9Q4zjj0kiUt5OO4Mr/A/jlI2jDYs5eHBpYHPcBEVSiipAvn2Ko2HnPe20rmcuuvMHNdZFp+4IlGTMF0Ow==",
"dependencies": {
"asynckit": "^0.4.0",
"combined-stream": "^1.0.8",
"es-set-tostringtag": "^2.1.0",
"hasown": "^2.0.2",
"mime-types": "^2.1.12"
},
"engines": {
@ -2243,9 +2251,9 @@
"integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw=="
},
"node_modules/brace-expansion": {
"version": "1.1.11",
"resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz",
"integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==",
"version": "1.1.12",
"resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.12.tgz",
"integrity": "sha512-9T9UjW3r0UW5c1Q7GTwllptXwhvYmEzFhzMfZ9H7FQWt+uZePjZPjBP/W1ZEyZ1twGWom5/56TF4lPcqjnDHcg==",
"dependencies": {
"balanced-match": "^1.0.0",
"concat-map": "0.0.1"
@ -2322,6 +2330,18 @@
"integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==",
"dev": true
},
"node_modules/call-bind-apply-helpers": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/call-bind-apply-helpers/-/call-bind-apply-helpers-1.0.2.tgz",
"integrity": "sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ==",
"dependencies": {
"es-errors": "^1.3.0",
"function-bind": "^1.1.2"
},
"engines": {
"node": ">= 0.4"
}
},
"node_modules/callsites": {
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz",
@ -2596,6 +2616,19 @@
"node": ">=6.0.0"
}
},
"node_modules/dunder-proto": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/dunder-proto/-/dunder-proto-1.0.1.tgz",
"integrity": "sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A==",
"dependencies": {
"call-bind-apply-helpers": "^1.0.1",
"es-errors": "^1.3.0",
"gopd": "^1.2.0"
},
"engines": {
"node": ">= 0.4"
}
},
"node_modules/ejs": {
"version": "3.1.10",
"resolved": "https://registry.npmjs.org/ejs/-/ejs-3.1.10.tgz",
@ -2645,6 +2678,47 @@
"is-arrayish": "^0.2.1"
}
},
"node_modules/es-define-property": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.1.tgz",
"integrity": "sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g==",
"engines": {
"node": ">= 0.4"
}
},
"node_modules/es-errors": {
"version": "1.3.0",
"resolved": "https://registry.npmjs.org/es-errors/-/es-errors-1.3.0.tgz",
"integrity": "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==",
"engines": {
"node": ">= 0.4"
}
},
"node_modules/es-object-atoms": {
"version": "1.1.1",
"resolved": "https://registry.npmjs.org/es-object-atoms/-/es-object-atoms-1.1.1.tgz",
"integrity": "sha512-FGgH2h8zKNim9ljj7dankFPcICIK9Cp5bm+c2gQSYePhpaG5+esrLODihIorn+Pe6FGJzWhXQotPv73jTaldXA==",
"dependencies": {
"es-errors": "^1.3.0"
},
"engines": {
"node": ">= 0.4"
}
},
"node_modules/es-set-tostringtag": {
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.1.0.tgz",
"integrity": "sha512-j6vWzfrGVfyXxge+O0x5sh6cvxAog0a/4Rdd2K36zCMV5eJ+/+tOAngRO8cODMNWbVRdVlmGZQL2YS3yR8bIUA==",
"dependencies": {
"es-errors": "^1.3.0",
"get-intrinsic": "^1.2.6",
"has-tostringtag": "^1.0.2",
"hasown": "^2.0.2"
},
"engines": {
"node": ">= 0.4"
}
},
"node_modules/escalade": {
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz",
@ -3100,11 +3174,10 @@
}
},
"node_modules/filelist/node_modules/brace-expansion": {
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz",
"integrity": "sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==",
"version": "2.0.2",
"resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.2.tgz",
"integrity": "sha512-Jt0vHyM+jmUBqojB7E1NIYadt0vI0Qxjxd2TErW94wDz+E2LAm5vKMXXwg6ZZBTHPuUlDgQHKXvjGBdfcF1ZDQ==",
"dev": true,
"license": "MIT",
"dependencies": {
"balanced-match": "^1.0.0"
}
@ -3171,13 +3244,16 @@
"dev": true
},
"node_modules/form-data": {
"version": "2.5.1",
"resolved": "https://registry.npmjs.org/form-data/-/form-data-2.5.1.tgz",
"integrity": "sha512-m21N3WOmEEURgk6B9GLOE4RuWOFf28Lhh9qGYeNlGq4VDXUlJy2th2slBNU8Gp8EzloYZOibZJ7t5ecIrFSjVA==",
"version": "2.5.5",
"resolved": "https://registry.npmjs.org/form-data/-/form-data-2.5.5.tgz",
"integrity": "sha512-jqdObeR2rxZZbPSGL+3VckHMYtu+f9//KXBsVny6JSX/pa38Fy+bGjuG8eW/H6USNQWhLi8Num++cU2yOCNz4A==",
"dependencies": {
"asynckit": "^0.4.0",
"combined-stream": "^1.0.6",
"mime-types": "^2.1.12"
"combined-stream": "^1.0.8",
"es-set-tostringtag": "^2.1.0",
"hasown": "^2.0.2",
"mime-types": "^2.1.35",
"safe-buffer": "^5.2.1"
},
"engines": {
"node": ">= 0.12"
@ -3207,7 +3283,6 @@
"version": "1.1.2",
"resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz",
"integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==",
"dev": true,
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
@ -3230,6 +3305,29 @@
"node": "6.* || 8.* || >= 10.*"
}
},
"node_modules/get-intrinsic": {
"version": "1.3.0",
"resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.3.0.tgz",
"integrity": "sha512-9fSjSaos/fRIVIp+xSJlE6lfwhES7LNtKaCBIamHsjr2na1BiABJPo0mOjjz8GJDURarmCPGqaiVg5mfjb98CQ==",
"dependencies": {
"call-bind-apply-helpers": "^1.0.2",
"es-define-property": "^1.0.1",
"es-errors": "^1.3.0",
"es-object-atoms": "^1.1.1",
"function-bind": "^1.1.2",
"get-proto": "^1.0.1",
"gopd": "^1.2.0",
"has-symbols": "^1.1.0",
"hasown": "^2.0.2",
"math-intrinsics": "^1.1.0"
},
"engines": {
"node": ">= 0.4"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/get-package-type": {
"version": "0.1.0",
"resolved": "https://registry.npmjs.org/get-package-type/-/get-package-type-0.1.0.tgz",
@ -3239,6 +3337,18 @@
"node": ">=8.0.0"
}
},
"node_modules/get-proto": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/get-proto/-/get-proto-1.0.1.tgz",
"integrity": "sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g==",
"dependencies": {
"dunder-proto": "^1.0.1",
"es-object-atoms": "^1.0.0"
},
"engines": {
"node": ">= 0.4"
}
},
"node_modules/get-stream": {
"version": "6.0.1",
"resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz",
@ -3298,6 +3408,17 @@
"url": "https://github.com/sponsors/sindresorhus"
}
},
"node_modules/gopd": {
"version": "1.2.0",
"resolved": "https://registry.npmjs.org/gopd/-/gopd-1.2.0.tgz",
"integrity": "sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg==",
"engines": {
"node": ">= 0.4"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/graceful-fs": {
"version": "4.2.11",
"resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz",
@ -3319,11 +3440,35 @@
"node": ">=8"
}
},
"node_modules/has-symbols": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.1.0.tgz",
"integrity": "sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ==",
"engines": {
"node": ">= 0.4"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/has-tostringtag": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.2.tgz",
"integrity": "sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw==",
"dependencies": {
"has-symbols": "^1.0.3"
},
"engines": {
"node": ">= 0.4"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/hasown": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.0.tgz",
"integrity": "sha512-vUptKVTpIJhcczKBbgnS+RtcuYMB8+oNzPK2/Hp3hanz8JmpATdmmgLgSaadVREkDm+e2giHwY3ZRkyjSIDDFA==",
"dev": true,
"version": "2.0.2",
"resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz",
"integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==",
"dependencies": {
"function-bind": "^1.1.2"
},
@ -4327,6 +4472,14 @@
"tmpl": "1.0.5"
}
},
"node_modules/math-intrinsics": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/math-intrinsics/-/math-intrinsics-1.1.0.tgz",
"integrity": "sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==",
"engines": {
"node": ">= 0.4"
}
},
"node_modules/merge-stream": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz",
@ -4960,6 +5113,25 @@
"queue-microtask": "^1.2.2"
}
},
"node_modules/safe-buffer": {
"version": "5.2.1",
"resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz",
"integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==",
"funding": [
{
"type": "github",
"url": "https://github.com/sponsors/feross"
},
{
"type": "patreon",
"url": "https://www.patreon.com/feross"
},
{
"type": "consulting",
"url": "https://feross.org/support"
}
]
},
"node_modules/sax": {
"version": "1.3.0",
"resolved": "https://registry.npmjs.org/sax/-/sax-1.3.0.tgz",
@ -5342,9 +5514,10 @@
}
},
"node_modules/undici-types": {
"version": "5.26.5",
"resolved": "https://registry.npmjs.org/undici-types/-/undici-types-5.26.5.tgz",
"integrity": "sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA=="
"version": "7.8.0",
"resolved": "https://registry.npmjs.org/undici-types/-/undici-types-7.8.0.tgz",
"integrity": "sha512-9UJ2xGDvQ43tYyVMpuHlsgApydB8ZKfVYTsLDhXkFL/6gfkp+U8xTGdh8pMJv1SpZna0zxG1DwsKZsreLbXBxw==",
"license": "MIT"
},
"node_modules/update-browserslist-db": {
"version": "1.0.13",

View File

@ -1,9 +1,12 @@
{
"name": "setup-java",
"version": "4.0.0",
"version": "5.0.0",
"private": true,
"description": "setup java action",
"main": "dist/setup/index.js",
"engines": {
"node": ">=24.0.0"
},
"scripts": {
"build": "ncc build -o dist/setup src/setup-java.ts && ncc build -o dist/cleanup src/cleanup-java.ts",
"format": "prettier --no-error-on-unmatched-pattern --config ./.prettierrc.js --write \"**/*.{ts,yml,yaml}\"",
@ -38,7 +41,7 @@
},
"devDependencies": {
"@types/jest": "^29.5.14",
"@types/node": "^20.11.24",
"@types/node": "^24.1.0",
"@types/semver": "^7.5.8",
"@typescript-eslint/eslint-plugin": "^8.35.1",
"@typescript-eslint/parser": "^8.35.1",