Turn on explicit API for Kotlin JVM projects (#1568)
This commit is contained in:
parent
d9727f7a4c
commit
208eed4269
6 changed files with 23 additions and 3 deletions
|
@ -6,6 +6,7 @@
|
|||
plugins {
|
||||
id("com.github.android-password-store.android-library")
|
||||
id("com.github.android-password-store.kotlin-android")
|
||||
id("com.github.android-password-store.kotlin-library")
|
||||
id("com.vanniktech.maven.publish")
|
||||
id("org.jetbrains.dokka")
|
||||
id("com.github.android-password-store.psl-plugin")
|
||||
|
|
|
@ -0,0 +1,17 @@
|
|||
/*
|
||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||
* SPDX-License-Identifier: GPL-3.0-only
|
||||
*/
|
||||
|
||||
import org.gradle.kotlin.dsl.withType
|
||||
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
|
||||
|
||||
plugins { id("com.github.android-password-store.kotlin-common") }
|
||||
|
||||
tasks.withType<KotlinCompile>().configureEach {
|
||||
kotlinOptions {
|
||||
if (!name.contains("test", ignoreCase = true)) {
|
||||
freeCompilerArgs += listOf("-Xexplicit-api=strict")
|
||||
}
|
||||
}
|
||||
}
|
|
@ -4,7 +4,7 @@
|
|||
*/
|
||||
plugins {
|
||||
kotlin("jvm")
|
||||
id("com.github.android-password-store.kotlin-common")
|
||||
id("com.github.android-password-store.kotlin-library")
|
||||
}
|
||||
|
||||
dependencies { implementation(libs.thirdparty.kotlinResult) }
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
|
||||
plugins {
|
||||
kotlin("jvm")
|
||||
id("com.github.android-password-store.kotlin-common")
|
||||
id("com.github.android-password-store.kotlin-library")
|
||||
}
|
||||
|
||||
dependencies {
|
||||
|
|
|
@ -2,9 +2,10 @@
|
|||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||
* SPDX-License-Identifier: GPL-3.0-only
|
||||
*/
|
||||
|
||||
plugins {
|
||||
kotlin("jvm")
|
||||
id("com.github.android-password-store.kotlin-common")
|
||||
id("com.github.android-password-store.kotlin-library")
|
||||
}
|
||||
|
||||
dependencies {
|
||||
|
|
|
@ -6,6 +6,7 @@
|
|||
plugins {
|
||||
id("com.github.android-password-store.android-library")
|
||||
id("com.github.android-password-store.kotlin-android")
|
||||
id("com.github.android-password-store.kotlin-library")
|
||||
id("com.vanniktech.maven.publish")
|
||||
id("org.jetbrains.dokka")
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue