KenCommandAPI/kencommandapi-bukkit/build.gradle.kts
2026-04-15 22:01:49 +02:00

59 lines
1.5 KiB
Kotlin

val scrowToken = providers.gradleProperty("scrowMavenToken")
.orElse(providers.environmentVariable("SCROW_MAVEN_TOKEN")).get()
plugins {
id("java")
id("java-library")
id("maven-publish")
id("io.freefair.lombok") version "9.2.0"
}
group = "de.kentoj"
version = "1.0.0"
fun scrowRepo(handler: RepositoryHandler) = handler.maven {
name = "scrow"
url = uri("http://forge.kentoj.de/api/packages/scrow/maven")
isAllowInsecureProtocol = true
credentials(HttpHeaderCredentials::class) {
name = "Authorization"
value = "token $scrowToken"
}
authentication {
create<HttpHeaderAuthentication>("header")
}
}
repositories {
mavenCentral()
maven("https://hub.spigotmc.org/nexus/content/repositories/snapshots/") {
name = "spigotmc-repo"
}
scrowRepo(this)
}
dependencies {
// https://mvnrepository.com/artifact/org.jetbrains/annotations
implementation("org.jetbrains:annotations:26.0.2-1")
api("de.kentoj:kencommandapi-core:1.0.0")
api("org.spigotmc:spigot-api:1.21.11-R0.1-SNAPSHOT")
implementation("org.spigotmc:spigot-api:1.21.11-R0.1-SNAPSHOT")
}
publishing {
publications {
create<MavenPublication>("KenCommandAPIBukkit") {
groupId = project.group.toString()
artifactId = "kencommandapi-bukkit"
version = project.version.toString()
from(components["java"])
}
}
repositories {
scrowRepo(this)
}
}