fix for openlogic mac builds

This commit is contained in:
Gerrit Grunwald 2021-04-26 12:11:12 +02:00
commit 32194ad1c2
4 changed files with 10 additions and 10 deletions

View file

@ -1043,7 +1043,7 @@ exports.DISTROS = [
'microsoft', 'microsoft',
'ojdk_build', 'ojdk_build',
'oracle_openjdk', 'oracle_openjdk',
'open_logic', 'openlogic',
'sap_machine', 'sap_machine',
'trava', 'trava',
'zulu' 'zulu'

7
dist/setup/index.js vendored
View file

@ -25780,7 +25780,7 @@ exports.DISTROS = [
'microsoft', 'microsoft',
'ojdk_build', 'ojdk_build',
'oracle_openjdk', 'oracle_openjdk',
'open_logic', 'openlogic',
'sap_machine', 'sap_machine',
'trava', 'trava',
'zulu' 'zulu'
@ -33687,7 +33687,7 @@ function getDownloadInfo(refs, version, arch, javaPackage, distro = 'zulu') {
distribution = distro.toLowerCase(); distribution = distro.toLowerCase();
} }
else { else {
throw new Error(`distro argument '${distro}' is not in [aoj | aoj_openj9 | corretto | dragonwell | liberica | microsoft | ojdk_build | open_logic | oracle_openjdk | sap_machine | trava | zulu]`); throw new Error(`distro argument '${distro}' is not in [aoj | aoj_openj9 | corretto | dragonwell | liberica | microsoft | ojdk_build | openlogic | oracle_openjdk | sap_machine | trava | zulu]`);
} }
} }
else { else {
@ -33701,7 +33701,8 @@ function getDownloadInfo(refs, version, arch, javaPackage, distro = 'zulu') {
else { else {
if (process.platform === 'darwin') { if (process.platform === 'darwin') {
operatingSystem = 'macos'; operatingSystem = 'macos';
archiveType = ((distribution === 'liberica') || (distribution === 'open_logic')) ? 'zip' : 'tar.gz'; let zipArchive = distribution === 'liberica' || distribution === 'openlogic';
archiveType = zipArchive ? 'zip' : 'tar.gz';
} }
else { else {
operatingSystem = 'linux'; operatingSystem = 'linux';

View file

@ -28,7 +28,7 @@ export const DISTROS: string[] = [
'microsoft', 'microsoft',
'ojdk_build', 'ojdk_build',
'oracle_openjdk', 'oracle_openjdk',
'open_logic', 'openlogic',
'sap_machine', 'sap_machine',
'trava', 'trava',
'zulu' 'zulu'

View file

@ -213,7 +213,7 @@ async function getDownloadInfo(
distribution = distro.toLowerCase(); distribution = distro.toLowerCase();
} else { } else {
throw new Error( throw new Error(
`distro argument '${distro}' is not in [aoj | aoj_openj9 | corretto | dragonwell | liberica | microsoft | ojdk_build | open_logic | oracle_openjdk | sap_machine | trava | zulu]` `distro argument '${distro}' is not in [aoj | aoj_openj9 | corretto | dragonwell | liberica | microsoft | ojdk_build | openlogic | oracle_openjdk | sap_machine | trava | zulu]`
); );
} }
} else { } else {
@ -226,10 +226,9 @@ async function getDownloadInfo(
} else { } else {
if (process.platform === 'darwin') { if (process.platform === 'darwin') {
operatingSystem = 'macos'; operatingSystem = 'macos';
archiveType = let zipArchive =
distribution === 'liberica' || distribution === 'open_logic' distribution === 'liberica' || distribution === 'openlogic';
? 'zip' archiveType = zipArchive ? 'zip' : 'tar.gz';
: 'tar.gz';
} else { } else {
operatingSystem = 'linux'; operatingSystem = 'linux';
archiveType = distribution === 'ojdk_build' ? 'zip' : 'tar.gz'; archiveType = distribution === 'ojdk_build' ? 'zip' : 'tar.gz';