diff --git a/build.gradle.kts b/build.gradle.kts index f2f1ceb..f4ebe39 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -1,13 +1,31 @@ plugins { kotlin("multiplatform") version "2.4.10" apply false kotlin("plugin.serialization") version "2.4.10" apply false + id("maven-publish") } +val libVersion = providers.gradleProperty("libVersion").get() + allprojects { group = "cn.rtast.bldm" - version = "1.0-SNAPSHOT" + version = libVersion repositories { mavenCentral() } +} + +subprojects { + pluginManager.apply("maven-publish") + + publishing { + repositories { + maven("https://repo.maven.rtast.cn/snapshots") { + credentials { + username = "RTAkland" + password = System.getenv("PUBLISH_TOKEN") + } + } + } + } } \ No newline at end of file diff --git a/gradle.properties b/gradle.properties index b89b623..ed1edd3 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,3 +1,5 @@ kotlin.code.style=official org.gradle.jvmargs=-Xmx2048m -XX:MaxMetaspaceSize=1024m -XX:+HeapDumpOnOutOfMemoryError -kotlin.native.ignoreDisabledTargets=true \ No newline at end of file +kotlin.native.ignoreDisabledTargets=true + +libVersion=0.1-snapshots \ No newline at end of file