Skip to content

Commit 0547b21

Browse files
committed
publish-to-sonatype
1 parent 807d896 commit 0547b21

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

build.gradle.kts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ plugins {
1717
id("me.champeau.gradle.jmh") version "0.5.3"
1818
id("io.freefair.maven-central.validate-poms") version "8.4"
1919
id("ru.vyarus.pom") version "2.2.2"
20+
id("io.codearte.nexus-staging") version "0.30.0"
2021
}
2122

2223
repositories {
@@ -234,6 +235,10 @@ publishing {
234235
publications {
235236
create<MavenPublication>("maven") {
236237
from(components["java"])
238+
if (isSnapshot && project.hasProperty("simplifyVersion")) {
239+
version = findProperty("git.ref.slug") as String + "-SNAPSHOT"
240+
}
241+
237242
pom {
238243
description.set("Collection of parsers for Language 1C (BSL) in ANTLR4 format.")
239244
url.set("https://github.com/1c-syntax/bsl-parser")
@@ -287,3 +292,8 @@ publishing {
287292
}
288293
}
289294
}
295+
296+
nexusStaging {
297+
serverUrl = "https://s01.oss.sonatype.org/service/local/"
298+
stagingProfileId = "15bd88b4d17915" // ./gradlew getStagingProfile
299+
}

0 commit comments

Comments
 (0)