mirror of
https://github.com/actions/setup-java.git
synced 2026-08-19 04:02:51 +00:00
Fail on mismatched Maven toolchain ID counts (#1161)
* Fail on mismatched Maven toolchain IDs Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 8c821981-7b21-45fe-9463-5bb375d7dce4 * Clarify Maven toolchain ID version counts Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 8c821981-7b21-45fe-9463-5bb375d7dce4 --------- Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 8c821981-7b21-45fe-9463-5bb375d7dce4
This commit is contained in:
co-authored by
Copilot App
parent
ce75feb3d3
commit
e1ce3a3428
+5
-5
@@ -40,18 +40,18 @@ async function run() {
|
||||
);
|
||||
const verifySignaturePublicKey =
|
||||
core.getInput(constants.INPUT_VERIFY_SIGNATURE_PUBLIC_KEY) || undefined;
|
||||
let toolchainIds = core.getMultilineInput(constants.INPUT_MVN_TOOLCHAIN_ID);
|
||||
const toolchainIds = core.getMultilineInput(
|
||||
constants.INPUT_MVN_TOOLCHAIN_ID
|
||||
);
|
||||
|
||||
core.startGroup('Installed distributions');
|
||||
|
||||
if (versions.length !== toolchainIds.length) {
|
||||
toolchainIds = [];
|
||||
}
|
||||
|
||||
if (!versions.length && !versionFile) {
|
||||
throw new Error('java-version or java-version-file input expected');
|
||||
}
|
||||
|
||||
toolchains.validateToolchainIds(versions, versionFile, toolchainIds);
|
||||
|
||||
if (!versions.length) {
|
||||
core.debug(
|
||||
'java-version input is empty, looking for java-version-file input'
|
||||
|
||||
Reference in New Issue
Block a user