-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
34 lines (31 loc) · 1.08 KB
/
build.gradle
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
import org.jetbrains.kotlin.gradle.plugin.KotlinPluginWrapperKt
plugins {
alias(libs.plugins.starter.config)
alias(libs.plugins.starter.versioning)
alias(libs.plugins.starter.library.kotlin) apply false
}
commonConfig {
javaVersion JavaVersion.VERSION_11
}
allprojects {
pluginManager.withPlugin("kotlin") { plugin ->
def kotlinVersion = KotlinPluginWrapperKt.getKotlinPluginVersion(project)
configurations.matching { it.name != "detekt" }.configureEach {
resolutionStrategy.eachDependency {
if (requested.group == 'org.jetbrains.kotlin' && requested.name.startsWith("kotlin")) {
useVersion kotlinVersion
}
}
}
kotlin {
jvmToolchain(libs.versions.java.compilation.get().toInteger())
}
}
pluginManager.withPlugin("java") {
if (project.hasProperty("skipJarVersion")) {
tasks.named("jar") {
archiveFile.set(project.layout.buildDirectory.map { it.file("libs/${project.name}.jar")})
}
}
}
}