kommons/guava/build.gradle.kts

45 lines
951 B
Plaintext

plugins {
kotlin("jvm")
`maven-publish`
}
val guavaDepVersion: String by project
val specifyKotlinAsDependency: String by project
repositories {
mavenCentral()
}
dependencies {
testImplementation("org.jetbrains.kotlin:kotlin-test")
implementation("com.google.guava:guava:$guavaDepVersion-jre")
}
tasks {
jar {
manifest {
attributes(
"Automatic-Module-Name" to "ru.dbotthepony.kommons.guava"
)
}
}
}
publishing {
publications {
create<MavenPublication>("mavenJava") {
from(components["java"])
artifact(tasks["sourceJar"])
artifactId = "kommons-guava"
pom {
dependencies {
if (specifyKotlinAsDependency.toBoolean()) implementation(kotlin("stdlib"))
implementation("com.google.guava:guava:[28,)")
}
}
}
}
}