Skip to content

Commit 6455e7c

Browse files
Remove buildLogicTargetJavaVersion
1 parent b3eed29 commit 6455e7c

File tree

1 file changed

+0
-15
lines changed

1 file changed

+0
-15
lines changed

build-logic/build.gradle.kts

-15
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
2-
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
3-
41
plugins {
52
`kotlin-dsl`
63
}
@@ -20,18 +17,6 @@ kotlin {
2017
)
2118
}
2219

23-
// TODO: Remove setting `options.release` and `compilerOptions.jvmTarget` after upgrade to Kotlin Gradle Plugin 1.9
24-
// build-logic is an internal project and given we know how the "actual" project is built - it's fine to target current java here as well.
25-
// @see https://github.com/pinterest/ktlint/pull/2120#discussion_r1260229055 for more details
26-
val buildLogicTargetJavaVersion = JavaVersion.VERSION_17
27-
tasks.withType<JavaCompile>().configureEach {
28-
options.release = buildLogicTargetJavaVersion.majorVersion.toInt()
29-
}
30-
tasks.withType<KotlinCompile>().configureEach {
31-
// Convert Java version (e.g. "1.8" or "11") to Kotlin JvmTarget ("8" resp. "11")
32-
compilerOptions.jvmTarget = JvmTarget.fromTarget(buildLogicTargetJavaVersion.toString())
33-
}
34-
3520
dependencies {
3621
val kotlinPlugin =
3722
if (hasProperty("kotlinDev")) {

0 commit comments

Comments
 (0)