mirror of
https://github.com/actions/setup-java.git
synced 2026-08-07 22:49:28 +08:00
Fix failing GitHub Actions job for graalvm 24-ea (#1227)
* Initial plan * Normalize EA setup-java version output in verify-java.sh Co-authored-by: brunoborges <129743+brunoborges@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: brunoborges <129743+brunoborges@users.noreply.github.com> Co-authored-by: Bruno Borges <brborges@microsoft.com>
This commit is contained in:
@@ -35,6 +35,9 @@ fi
|
||||
|
||||
if [ -n "$SETUP_JAVA_VERSION" ]; then
|
||||
OUTPUT_JAVA_VERSION=$(echo "$SETUP_JAVA_VERSION" | cut -d'+' -f1)
|
||||
if [[ $OUTPUT_JAVA_VERSION == *-ea* ]]; then
|
||||
OUTPUT_JAVA_VERSION=$(echo "$OUTPUT_JAVA_VERSION" | cut -d'-' -f1 | cut -d'.' -f1)
|
||||
fi
|
||||
OUTPUT_GREP_RESULT=$(echo "$ACTUAL_JAVA_VERSION" | grep -E "^(openjdk|java) version \"$OUTPUT_JAVA_VERSION")
|
||||
if [ -z "$OUTPUT_GREP_RESULT" ]; then
|
||||
echo "::error::The version output does not match the installed Java version"
|
||||
|
||||
Reference in New Issue
Block a user