From d4198589e4846acfb2aff5e646b99cad06dd7275 Mon Sep 17 00:00:00 2001 From: Username404-59 Date: Thu, 8 Apr 2021 11:35:51 +0200 Subject: [PATCH] Fully target Java 8. --- build.gradle.kts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/build.gradle.kts b/build.gradle.kts index a7fab4b..6323093 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -27,7 +27,7 @@ allprojects { apply(plugin = "architectury-plugin") java { targetCompatibility = JavaVersion.VERSION_1_8 - sourceCompatibility = JavaVersion.VERSION_11 + sourceCompatibility = JavaVersion.VERSION_1_8 } tasks { withType(com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar::class) { @@ -51,8 +51,9 @@ allprojects { withType(JavaCompile::class) { with(options) { encoding = "UTF-8" - release.set(8) - isFork = true + if (JavaVersion.current().isJava9Compatible) { + release.set(8) + }; isFork = true } } withType(net.fabricmc.loom.task.RemapJarTask::class) {