fix(build): switch kotlin-library plugin to compilerOptions
DSL
This commit is contained in:
parent
57670ea047
commit
9348b7c444
1 changed files with 4 additions and 4 deletions
|
@ -16,10 +16,10 @@ class KotlinLibraryPlugin : Plugin<Project> {
|
|||
|
||||
override fun apply(project: Project) {
|
||||
project.pluginManager.apply(KotlinCommonPlugin::class)
|
||||
project.tasks.withType<KotlinCompile>().configureEach {
|
||||
kotlinOptions {
|
||||
if (!name.contains("test", ignoreCase = true)) {
|
||||
freeCompilerArgs = freeCompilerArgs + listOf("-Xexplicit-api=strict")
|
||||
project.tasks.withType<KotlinCompile>().configureEach task@{
|
||||
compilerOptions {
|
||||
if (!this@task.name.contains("test", ignoreCase = true)) {
|
||||
freeCompilerArgs.add("-Xexplicit-api=strict")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue