Skip to content

Commit d33f503

Browse files
committed
Refactor Kotlin compile options to use JvmTarget for jvmVersion
1 parent 22bbcd0 commit d33f503

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

build.gradle.kts

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
12
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
23

34
plugins {
@@ -14,8 +15,8 @@ allprojects {
1415
apply(plugin = "org.jetbrains.kotlin.jvm")
1516

1617
tasks.withType(KotlinCompile::class.java) {
17-
kotlinOptions {
18-
jvmTarget = jvmVersion
18+
compilerOptions {
19+
jvmTarget = JvmTarget.fromTarget(jvmVersion)
1920
}
2021
}
2122

@@ -53,8 +54,7 @@ allprojects {
5354
},
5455
)
5556
trimTrailingWhitespace()
56-
indentWithTabs(2)
57-
indentWithSpaces(4)
57+
leadingTabsToSpaces(4)
5858
endWithNewline()
5959
ktlint()
6060
}

0 commit comments

Comments
 (0)