mirror of
https://github.com/actions/setup-java.git
synced 2025-04-20 09:56:46 +00:00
build
This commit is contained in:
parent
4966150d90
commit
d5d37d43c2
2 changed files with 14 additions and 2 deletions
|
@ -1,3 +1,4 @@
|
|||
import fs from "fs";
|
||||
import * as core from '@actions/core';
|
||||
import * as auth from './auth';
|
||||
import { getBooleanInput, isCacheFeatureAvailable } from './util';
|
||||
|
@ -11,7 +12,6 @@ import { JavaInstallerOptions } from './distributions/base-models';
|
|||
async function run() {
|
||||
try {
|
||||
const versions = core.getMultilineInput(constants.INPUT_JAVA_VERSION);
|
||||
core.info(versions.join(" "))
|
||||
const distributionName = core.getInput(constants.INPUT_DISTRIBUTION, { required: true });
|
||||
const architecture = core.getInput(constants.INPUT_ARCHITECTURE);
|
||||
const packageType = core.getInput(constants.INPUT_JAVA_PACKAGE);
|
||||
|
@ -20,6 +20,11 @@ async function run() {
|
|||
const checkLatest = getBooleanInput(constants.INPUT_CHECK_LATEST, false);
|
||||
let toolchainIds = core.getMultilineInput(constants.INPUT_MVN_TOOLCHAIN_ID);
|
||||
|
||||
if (!versions.length) {
|
||||
const contents = fs.readFileSync('.java-version').toString();
|
||||
core.info(contents)
|
||||
}
|
||||
|
||||
if (versions.length !== toolchainIds.length) {
|
||||
toolchainIds = [];
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue