Update publishTo to use Central Portal URLs and localStaging

- Use https://central.sonatype.com/repository/maven-snapshots/ for snapshots
- Use localStaging.value for releases to support sonaRelease workflow
This commit is contained in:
Taro L. Saito 2025-07-19 11:10:17 -07:00
parent fc0812b1dc
commit 61e8ef98c6

View File

@ -6,9 +6,9 @@ organizationName := "xerial.org"
description := "snappy-java: A fast compression/decompression library"
ThisBuild / publishTo := {
val nexus = "https://s01.oss.sonatype.org/"
if (isSnapshot.value) Some("snapshots" at nexus + "content/repositories/snapshots")
else Some("releases" at nexus + "service/local/staging/deploy/maven2")
val centralSnapshots = "https://central.sonatype.com/repository/maven-snapshots/"
if (isSnapshot.value) Some("central-snapshots" at centralSnapshots)
else localStaging.value
}
licenses := Seq("Apache-2.0" -> url("https://www.apache.org/licenses/LICENSE-2.0.html"))
homepage := Some(url("https://github.com/xerial/snappy-java"))