plugins { val kotlinVersion = "1.3.71" kotlin("js") version kotlinVersion apply false kotlin("jvm") version kotlinVersion apply false kotlin("multiplatform") version kotlinVersion apply false kotlin("plugin.spring") version kotlinVersion apply false id("org.jetbrains.kotlin.plugin.serialization") version kotlinVersion apply false id("org.jlleitschuh.gradle.ktlint") version "9.1.1" apply false } subprojects { repositories { jcenter() } val compilerArgs = listOf("-Xopt-in=kotlin.RequiresOptIn") tasks.withType { kotlinOptions.jvmTarget = "1.8" kotlinOptions.freeCompilerArgs += compilerArgs } tasks.withType { kotlinOptions.freeCompilerArgs = compilerArgs } tasks.withType { testLogging { events("failed", "standardError") exceptionFormat = org.gradle.api.tasks.testing.logging.TestExceptionFormat.FULL showStackTraces = true } } afterEvaluate { // The import ordering expected by ktlint is alphabetical, which doesn't match IDEA's formatter. // Since it is not configurable, we have to disable the rule. // https://github.com/pinterest/ktlint/issues/527 extensions.configure { disabledRules.set(setOf("import-ordering", "no-wildcard-imports")) } } }