This commit is contained in:
Danny McCormick 2019-07-15 14:00:08 -04:00
parent 55f787ebb1
commit 9f0c2dfa0d
2 changed files with 7 additions and 2 deletions

View File

@ -49,10 +49,13 @@ function getJava(version, arch, jdkFile) {
else {
let compressedFileExtension = '';
if (!jdkFile) {
core.debug('Downloading Jdk from Azul');
jdkFile = yield downloadJava(version);
compressedFileExtension = IS_WINDOWS ? '.zip' : '.tar.gz';
}
core.debug('Retrieving Jdk from local path');
else {
core.debug('Retrieving Jdk from local path');
}
compressedFileExtension = compressedFileExtension || getFileEnding(jdkFile);
let tempDir = path.join(tempDirectory, 'temp_' + Math.floor(Math.random() * 2000000000));
const jdkDir = yield unzipJavaDownload(jdkFile, compressedFileExtension, tempDir);

View File

@ -37,10 +37,12 @@ export async function getJava(
} else {
let compressedFileExtension = '';
if (!jdkFile) {
core.debug('Downloading Jdk from Azul');
jdkFile = await downloadJava(version);
compressedFileExtension = IS_WINDOWS ? '.zip' : '.tar.gz';
} else {
core.debug('Retrieving Jdk from local path');
}
core.debug('Retrieving Jdk from local path');
compressedFileExtension = compressedFileExtension || getFileEnding(jdkFile);
let tempDir: string = path.join(
tempDirectory,