Skip to content

Commit 7dfab00

Browse files
committed
ci: run Gradle on JDK 21, expose JDK 25 toolchain via env
Gradle 8.14.3 cannot run on JDK 25 ('Unsupported class file major version 69'), so the full-JDK-25 runtime broke the build script compilation. Keep the Gradle runtime on JDK 21 (last entry, so it is the default JAVA_HOME) and additionally install JDK 25, exposing it to Gradle toolchain detection via org.gradle.java.installations.fromEnv so only the Java 25 Minestom modules use it. https://claude.ai/code/session_01S76fk9ma5Szkf9r1W44RVP
1 parent 76582a8 commit 7dfab00

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

.github/workflows/ci.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,15 @@ jobs:
2828
uses: actions/setup-java@v4
2929
with:
3030
distribution: 'temurin'
31-
java-version: '25'
31+
java-version: |
32+
25
33+
21
3234
3335
- name: Setup Gradle
3436
uses: gradle/actions/setup-gradle@v4
3537

3638
- name: Run build and tests with Gradle wrapper
37-
run: ./gradlew test build publish cyclonedxBom -PdockerTests
39+
run: ./gradlew test build publish cyclonedxBom -PdockerTests -Dorg.gradle.java.installations.fromEnv=JAVA_HOME_25_X64
3840
env:
3941
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4042
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

0 commit comments

Comments
 (0)