diff --git a/build.gradle.kts b/build.gradle.kts index 8a50185af8..6b0aad4341 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -1,3 +1,5 @@ +import org.jetbrains.kotlin.gradle.tasks.KotlinCompilationTask + @Suppress("DSL_SCOPE_VIOLATION") plugins { alias(libs.plugins.kotlin.jvm) @@ -12,6 +14,12 @@ java { targetCompatibility = JavaVersion.VERSION_1_8 } +tasks.named("compileKotlin", KotlinCompilationTask::class.java) { + compilerOptions { + freeCompilerArgs.addAll("-Xjdk-release=1.8") + } +} + detekt { buildUponDefaultConfig = true allRules = false diff --git a/maestro-ios-driver/build.gradle b/maestro-ios-driver/build.gradle index 3510019d0e..58e6320e15 100644 --- a/maestro-ios-driver/build.gradle +++ b/maestro-ios-driver/build.gradle @@ -1,3 +1,5 @@ +import org.jetbrains.kotlin.gradle.tasks.KotlinCompilationTask + plugins { id("maven-publish") alias(libs.plugins.kotlin.jvm) @@ -26,6 +28,12 @@ java { targetCompatibility = JavaVersion.VERSION_1_8 } +tasks.named("compileKotlin", KotlinCompilationTask) { + compilerOptions { + freeCompilerArgs.addAll("-Xjdk-release=1.8") + } +} + plugins.withId("com.vanniktech.maven.publish") { mavenPublish { sonatypeHost = "S01" diff --git a/maestro-orchestra-models/build.gradle b/maestro-orchestra-models/build.gradle index 8266b5ab2f..bc6dc1ed80 100644 --- a/maestro-orchestra-models/build.gradle +++ b/maestro-orchestra-models/build.gradle @@ -1,3 +1,5 @@ +import org.jetbrains.kotlin.gradle.tasks.KotlinCompilationTask + plugins { id("maven-publish") alias(libs.plugins.kotlin.jvm) @@ -15,6 +17,12 @@ java { targetCompatibility = JavaVersion.VERSION_1_8 } +tasks.named("compileKotlin", KotlinCompilationTask) { + compilerOptions { + freeCompilerArgs.addAll("-Xjdk-release=1.8") + } +} + dependencies { implementation(project(path: ":maestro-client")) diff --git a/maestro-studio/server/build.gradle b/maestro-studio/server/build.gradle index 44271e8393..f17ee90c57 100644 --- a/maestro-studio/server/build.gradle +++ b/maestro-studio/server/build.gradle @@ -35,6 +35,12 @@ java { targetCompatibility = JavaVersion.VERSION_1_8 } +tasks.named("compileKotlin", KotlinCompilationTask::class.java) { + compilerOptions { + freeCompilerArgs.addAll("-Xjdk-release=1.8") + } +} + dependencies { implementation(project(":maestro-orchestra")) implementation(project(":maestro-client"))