Files
mac.kt/build.gradle.kts
Infendro cff4a4e7a4
All checks were successful
/ publish (push) Successful in 2m32s
bump version to 1.2.1
2025-11-10 16:10:59 +01:00

61 lines
1.2 KiB
Kotlin

group = "com.infendro"
version = "1.2.1"
repositories {
maven("https://git.infendro.com/api/packages/Infendro/maven")
mavenCentral()
}
plugins {
alias(libs.plugins.multiplatform)
id("maven-publish")
}
kotlin {
jvm()
js {
nodejs()
}
linuxX64()
sourceSets {
commonMain.dependencies {
implementation(libs.hash)
implementation(libs.bytearray)
}
}
compilerOptions {
freeCompilerArgs.add("-opt-in=kotlin.ExperimentalUnsignedTypes")
}
}
publishing {
repositories {
maven {
url = uri("https://git.infendro.com/api/packages/Infendro/maven")
authentication.create("header", HttpHeaderAuthentication::class)
credentials(HttpHeaderCredentials::class) {
val token = secret("git.token") ?: throw GradleException()
name = "Authorization"
value = "token $token"
}
}
}
}
fun secret(
key: String,
): String? {
val property = key
val environment = key
.uppercase()
.replace(".", "__")
val prop = properties[property] as String?
val env = System.getenv(environment)
return prop ?: env
}