aboutsummaryrefslogtreecommitdiff
path: root/build-logic/src/main/kotlin
diff options
context:
space:
mode:
Diffstat (limited to 'build-logic/src/main/kotlin')
-rw-r--r--build-logic/src/main/kotlin/app/passwordstore/gradle/AndroidCommon.kt1
-rw-r--r--build-logic/src/main/kotlin/app/passwordstore/gradle/KotlinCommonPlugin.kt6
2 files changed, 2 insertions, 5 deletions
diff --git a/build-logic/src/main/kotlin/app/passwordstore/gradle/AndroidCommon.kt b/build-logic/src/main/kotlin/app/passwordstore/gradle/AndroidCommon.kt
index 0d6b5cf7..ca324ccf 100644
--- a/build-logic/src/main/kotlin/app/passwordstore/gradle/AndroidCommon.kt
+++ b/build-logic/src/main/kotlin/app/passwordstore/gradle/AndroidCommon.kt
@@ -12,7 +12,6 @@ import org.gradle.kotlin.dsl.configure
import org.gradle.kotlin.dsl.findByType
import org.gradle.kotlin.dsl.withType
-@Suppress("UnstableApiUsage")
object AndroidCommon {
fun configure(project: Project) {
project.extensions.configure<TestedExtension> {
diff --git a/build-logic/src/main/kotlin/app/passwordstore/gradle/KotlinCommonPlugin.kt b/build-logic/src/main/kotlin/app/passwordstore/gradle/KotlinCommonPlugin.kt
index e7ca2219..067cadfc 100644
--- a/build-logic/src/main/kotlin/app/passwordstore/gradle/KotlinCommonPlugin.kt
+++ b/build-logic/src/main/kotlin/app/passwordstore/gradle/KotlinCommonPlugin.kt
@@ -16,8 +16,8 @@ import org.gradle.api.tasks.testing.logging.TestLogEvent
import org.gradle.kotlin.dsl.configure
import org.gradle.kotlin.dsl.withType
import org.gradle.language.base.plugins.LifecycleBasePlugin
+import org.jetbrains.kotlin.gradle.dsl.JvmTarget
import org.jetbrains.kotlin.gradle.dsl.KotlinVersion
-import org.jetbrains.kotlin.gradle.tasks.KotlinCompilationTask
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
@Suppress("Unused")
@@ -45,10 +45,8 @@ class KotlinCommonPlugin : Plugin<Project> {
targetCompatibility = JavaVersion.VERSION_11.toString()
}
withType<KotlinCompile>().configureEach {
- kotlinOptions { jvmTarget = JavaVersion.VERSION_11.toString() }
- }
- withType<KotlinCompilationTask<*>>().configureEach {
compilerOptions {
+ jvmTarget.set(JvmTarget.JVM_11)
allWarningsAsErrors.set(true)
languageVersion.set(KotlinVersion.KOTLIN_1_5)
freeCompilerArgs.addAll(ADDITIONAL_COMPILER_ARGS)