11val ScalaNativeVersion = " 0.5.8-SNAPSHOT"
2- // Update during release procedure to provide access to staged, but not published artifacts
3- val StagingRepoIds = Nil
4- val StagingRepoNames = StagingRepoIds .map(id => s " orgscala-native- $id" ).toSeq
52
63val crossScalaVersions212 = (14 to 20 ).map(" 2.12." + _)
74val crossScalaVersions213 = (8 to 16 ).map(" 2.13." + _)
85val crossScalaVersions3 =
96 (2 to 3 ).map(" 3.1." + _) ++
107 (0 to 2 ).map(" 3.2." + _) ++
11- (0 to 4 ).map(" 3.3." + _) ++
8+ (0 to 6 ).map(" 3.3." + _) ++
129 (0 to 3 ).map(" 3.4." + _) ++
1310 (0 to 2 ).map(" 3.5." + _) ++
14- (2 to 3 ).map(" 3.6." + _)
11+ (2 to 4 ).map(" 3.6." + _) ++
12+ (0 to 1 ).map(" 3.7." + _) ++
13+ Nil
1514
1615val scala2_12 = crossScalaVersions212.last
1716val scala2_13 = crossScalaVersions213.last
1817val scala3 = crossScalaVersions3.last
1918val scala3PublishVersion = " 3.1.3"
2019
20+ sonatypePublishSettings
21+
2122val publishScalaVersions = Seq (scala2_12, scala2_13, scala3PublishVersion)
2223
2324def scalaReleasesForBinaryVersion (v : String ): Seq [String ] = v match {
@@ -100,7 +101,7 @@ inThisBuild(
100101 )
101102 ),
102103 // Used during the releases
103- resolvers ++= StagingRepoNames .flatMap( Resolver .sonatypeOssRepos(_)) ,
104+ resolvers += " Sonatype Central Deployments " at " https://central.sonatype.com/api/v1/publisher/deployments/download/ " ,
104105 resolvers ++= Resolver .sonatypeOssRepos(" snapshots" ),
105106 resolvers += Resolver .mavenCentral,
106107 resolvers += Resolver .defaultLocal
@@ -154,9 +155,7 @@ lazy val cliScriptedTests = project
154155 " -Dplugin.version=" + (cli / scalaNativeVersion).value,
155156 " -Dscala.version=" + (cli / scalaVersion).value,
156157 " -Dscala-native-cli=" + cliPath,
157- " -Dscala-native-cli-pack=" + packDir,
158- " -Dscalanative.build.staging.resolvers=" + StagingRepoNames
159- .mkString(" ," )
158+ " -Dscala-native-cli-pack=" + packDir
160159 )
161160 },
162161 scriptedBufferLog := false ,
@@ -306,6 +305,9 @@ lazy val cliPackSettings = Def.settings(
306305lazy val publishSettings = Def .settings(
307306 Compile / publishArtifact := true ,
308307 Test / publishArtifact := false ,
308+ sonatypePublishSettings
309+ )
310+ lazy val sonatypePublishSettings = Def .settings(
309311 publishMavenStyle := true ,
310312 pomIncludeRepository := (_ => false ),
311313 publishTo := {
@@ -319,7 +321,7 @@ lazy val publishSettings = Def.settings(
319321 user <- sys.env.get(" SONATYPE_USER" )
320322 password <- sys.env.get(" SONATYPE_PASSWORD" )
321323 } yield Credentials (
322- realm = " Sonatype Nexus Repository Manager " ,
324+ realm = " " ,
323325 host = " central.sonatype.com" ,
324326 userName = user,
325327 passwd = password
0 commit comments