kenkousen
11/26/2018, 10:36 PMbuild.gradle.kts
file, I want to specify that Kotlin compile to 1.8. I’m using the following syntax, which works, but I was wondering whether this is idiomatic or if there’s a simpler way:
tasks.withType<KotlinCompile> {
kotlinOptions {
jvmTarget = "1.8"
}
}
suresh
11/27/2018, 6:53 AMtasks.withType<KotlinCompile>().all {
kotlinOptions.jvmTarget = "1.8"
}
This will set the version for both main
and test
eskatos
11/27/2018, 7:54 AM.all()
call is unnecessarygildor
11/27/2018, 1:41 PMsuresh
11/27/2018, 7:10 PMgildor
11/28/2018, 1:15 AM