Skip to content

Commit

Permalink
Switch to sbt-ci-release
Browse files Browse the repository at this point in the history
  • Loading branch information
stanch committed Jul 10, 2024
1 parent 37ddf66 commit 07d9d5f
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 23 deletions.
8 changes: 6 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,9 @@ jobs:
distribution: 'temurin'
java-version: '17'
- uses: coursier/cache-action@v6
- run: |
sbt "+publishSigned; sonatypeReleaseAll"
- run: sbt ci-release
env:
PGP_SECRET: ${{ secrets.PGP_SECRET }}
PGP_PASSPHRASE: ${{ secrets.PGP_PASSPHRASE }}
SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }}
SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }}
Binary file removed .gnupg/pubring.gpg
Binary file not shown.
Binary file removed .gnupg/secring.gpg
Binary file not shown.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ create data structure visualizations with very little effort.
There are a few ways you can use `reftree`:

* [improving the documentation of your projects](https://stanch.github.io/zipper/);
* [live-coding demos and talks](https://stanch.github.io/reftree/Talks.html);
* [live-coding demos and talks](https://stanch.github.io/reftree/docs/talks);
* exploring how things work;
* anywhere you need diagrams of your Scala data structures.

Expand Down
19 changes: 2 additions & 17 deletions build.sbt
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
val commonSettings = Seq(
scalaVersion := "2.13.14",
crossScalaVersions := Seq("2.12.19", "2.13.14"),
version := "1.4.0",
scalacOptions ++= {
val commonScalacOptions =
Seq("-feature", "-deprecation", "-Xlint", "-Xfatal-warnings")
Expand All @@ -20,7 +19,7 @@ val commonSettings = Seq(
}
},
Compile / doc / scalacOptions += "-no-link-warnings"
) ++ metadata ++ publishing
) ++ metadata

lazy val metadata = Seq(
organization := "io.github.stanch",
Expand All @@ -38,20 +37,6 @@ lazy val metadata = Seq(
licenses := Seq(("GPL-3.0", url("http://www.gnu.org/licenses/gpl-3.0.en.html")))
)

lazy val publishing = Seq(
usePgpKeyHex("8ED74E385203BEB1"),
pgpPublicRing := baseDirectory.value.getParentFile.getParentFile / ".gnupg" / "pubring.gpg",
pgpSecretRing := baseDirectory.value.getParentFile.getParentFile / ".gnupg" / "secring.gpg",
pgpPassphrase := sys.env.get("PGP_PASS").map(_.toArray),
credentials += Credentials(
"Sonatype Nexus Repository Manager",
"oss.sonatype.org",
sys.env.getOrElse("SONATYPE_USER", ""),
sys.env.getOrElse("SONATYPE_PASS", "")
),
publishTo := Some(Opts.resolver.sonatypeStaging)
)

val core = crossProject(JSPlatform, JVMPlatform)
.in(file("core"))
.settings(commonSettings)
Expand Down Expand Up @@ -128,7 +113,7 @@ val site = project.in(file("site-gen"))
name := "reftree-site",
moduleName := "reftree-site",
mdocVariables := Map(
"VERSION" -> version.value
"VERSION" -> version.value.split('+').head
),
(publish / skip) := true
)
Expand Down
4 changes: 1 addition & 3 deletions project/plugins.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,4 @@ addSbtPlugin("org.scala-js" % "sbt-jsdependencies" % "1.0.2")

libraryDependencies += "net.exoego" %% "scalajs-env-jsdom-nodejs" % "2.1.0"

addSbtPlugin("com.github.sbt" % "sbt-dynver" % "5.0.1")
addSbtPlugin("org.xerial.sbt" % "sbt-sonatype" % "3.10.0")
addSbtPlugin("com.github.sbt" % "sbt-pgp" % "2.2.1")
addSbtPlugin("com.github.sbt" % "sbt-ci-release" % "1.5.12")

0 comments on commit 07d9d5f

Please sign in to comment.