mirror of
https://github.com/actions/setup-java.git
synced 2025-04-20 18:06:45 +00:00
Dont fail if jdkFile not set until checking cache
This commit is contained in:
parent
609f104c5b
commit
012e07621e
5 changed files with 11 additions and 3 deletions
|
@ -34,6 +34,11 @@ export async function getJava(
|
|||
if (toolPath) {
|
||||
core.debug(`Tool found in cache ${toolPath}`);
|
||||
} else {
|
||||
if (!jdkFile) {
|
||||
throw new Error(
|
||||
`Failed to find Java ${version} in the cache. Please specify a valid jdk file to install from instead.`
|
||||
);
|
||||
}
|
||||
core.debug('Retrieving Jdk from local path');
|
||||
const compressedFileExtension = getFileEnding(jdkFile);
|
||||
let tempDir: string = path.join(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue