mirror of
https://github.com/actions/setup-java.git
synced 2025-06-30 21:04:16 +00:00
fix an issue
This commit is contained in:
parent
4fa0d7379d
commit
bb06c65bfc
4 changed files with 3 additions and 19 deletions
10
dist/setup/index.js
vendored
10
dist/setup/index.js
vendored
|
@ -4068,15 +4068,6 @@ class JavaBase {
|
|||
version = version.replace('-ea.', '+');
|
||||
stable = false;
|
||||
}
|
||||
else if (version.endsWith('-beta')) {
|
||||
version = version.replace(/-beta$/, '');
|
||||
stable = false;
|
||||
}
|
||||
else if (version.includes('-beta+')) {
|
||||
// transform '11.0.0-beta+33' -> '11.0.3+33'
|
||||
version = version.replace('-beta', '');
|
||||
stable = false;
|
||||
}
|
||||
if (!semver_1.default.validRange(version)) {
|
||||
throw new Error(`The string '${version}' is not valid SemVer notation for a Java version. Please check README file for code snippets and more detailed information`);
|
||||
}
|
||||
|
@ -39946,6 +39937,7 @@ class TemurinDistribution extends base_installer_1.JavaBase {
|
|||
const availableVersionsWithBinaries = availableVersionsRaw
|
||||
.filter(item => item.binaries.length > 0)
|
||||
.map(item => {
|
||||
// normalize 17.0.0-beta+33.0.202107301459 to 17.0.0+33.0.202107301459 for earlier access versions
|
||||
const formattedVersion = this.stable
|
||||
? item.version_data.semver
|
||||
: item.version_data.semver.replace('-beta+', '+');
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue