From 1df01a2f5486f400cac35af49f2fc474c5206204 Mon Sep 17 00:00:00 2001 From: Harsh Shandilya Date: Tue, 7 Dec 2021 20:51:54 +0530 Subject: Upgrade workflows to use Java 17 (#1579) --- .../com.github.android-password-store.kotlin-common.gradle.kts | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'build-logic') diff --git a/build-logic/kotlin-plugins/src/main/kotlin/com.github.android-password-store.kotlin-common.gradle.kts b/build-logic/kotlin-plugins/src/main/kotlin/com.github.android-password-store.kotlin-common.gradle.kts index 71a68d9c..7ef59be9 100644 --- a/build-logic/kotlin-plugins/src/main/kotlin/com.github.android-password-store.kotlin-common.gradle.kts +++ b/build-logic/kotlin-plugins/src/main/kotlin/com.github.android-password-store.kotlin-common.gradle.kts @@ -4,6 +4,7 @@ */ import org.gradle.api.JavaVersion +import org.gradle.api.tasks.compile.JavaCompile import org.gradle.api.tasks.testing.Test import org.gradle.api.tasks.testing.logging.TestLogEvent import org.gradle.kotlin.dsl.withType @@ -11,6 +12,11 @@ import org.jetbrains.kotlin.gradle.tasks.KotlinCompile val additionalCompilerArgs = listOf("-Xopt-in=kotlin.RequiresOptIn") +tasks.withType().configureEach { + sourceCompatibility = JavaVersion.VERSION_11.toString() + targetCompatibility = JavaVersion.VERSION_11.toString() +} + tasks.withType().configureEach { kotlinOptions { allWarningsAsErrors = true -- cgit v1.2.3