-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle.kts
51 lines (40 loc) · 1.26 KB
/
build.gradle.kts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
import org.jetbrains.kotlin.gradle.dsl.KotlinJvmCompilerOptions
import org.jetbrains.kotlin.gradle.dsl.KotlinVersion
import org.jetbrains.kotlin.gradle.tasks.KotlinCompilationTask
group = property("GROUP").toString()
version = property("VERSION").toString()
plugins {
alias(libs.plugins.kotlin.mpp) apply false
}
allprojects {
repositories {
mavenCentral()
gradlePluginPortal()
}
}
subprojects {
tasks.withType(JavaCompile::class.java).all {
sourceCompatibility = JavaVersion.VERSION_1_8.toString()
targetCompatibility = JavaVersion.VERSION_1_8.toString()
}
tasks.withType(KotlinCompilationTask::class.java).all {
compilerOptions {
if (this is KotlinJvmCompilerOptions) {
jvmTarget.set(JvmTarget.JVM_1_8)
}
apiVersion.set(KotlinVersion.KOTLIN_2_0)
languageVersion.set(KotlinVersion.KOTLIN_2_0)
}
}
}
tasks.register("publish") {
group = "publishing"
dependsOn(gradle.includedBuild("plugin-build").task(":publish"))
}
tasks.register("publishToMavenLocal") {
group = "publishing"
dependsOn(
gradle.includedBuild("plugin-build").task(":publishToMavenLocal")
)
}