Skip to content

Commit fcb3cdf

Browse files
authored
Merge pull request #3 from EntglDb/copilot/update-publish-endpoints
Update Maven Central publication to new Sonatype Central Portal endpoints
2 parents 32264fc + 5277672 commit fcb3cdf

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

scripts/publish-module.gradle.kts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,9 +48,9 @@ afterEvaluate {
4848
repositories {
4949
maven {
5050
name = "OSSRH"
51-
val releasesRepoUrl = "https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/"
52-
val snapshotsRepoUrl = "https://s01.oss.sonatype.org/content/repositories/snapshots/"
53-
url = uri(if (version.toString().endsWith("SNAPSHOT")) snapshotsRepoUrl else releasesRepoUrl)
51+
// New Sonatype Central Portal uses unified endpoint for both releases and snapshots
52+
val repoUrl = "https://central.sonatype.com/api/v1/publisher/upload?publishingType=AUTOMATIC"
53+
url = uri(repoUrl)
5454

5555
credentials {
5656
username = findProperty("ossrhUsername") as String? ?: System.getenv("OSSRH_USERNAME")

0 commit comments

Comments
 (0)