diff --git a/.github/workflows/ci-release.yml b/.github/workflows/ci-release.yml new file mode 100644 index 0000000..77d315b --- /dev/null +++ b/.github/workflows/ci-release.yml @@ -0,0 +1,24 @@ +name: Release +on: + push: + branches: [master] + tags: ["*"] +jobs: + publish: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + - uses: actions/setup-java@v4 + with: + distribution: temurin + java-version: 8 + cache: sbt + - uses: sbt/setup-sbt@v1 + - run: sbt ci-release + env: + PGP_PASSPHRASE: ${{ secrets.PGP_PASSPHRASE }} + PGP_SECRET: ${{ secrets.PGP_SECRET }} + SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }} + SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }} diff --git a/build.sbt b/build.sbt index 92d0c5e..c5fa94e 100644 --- a/build.sbt +++ b/build.sbt @@ -47,6 +47,14 @@ val commonSettings = Seq( sonatypeProfileName := "testcontainers-scala", sonatypeProjectHosting := Some(GitHubHosting("testcontainers", "testcontainers-scala", "dimafeng@gmail.com")), licenses := Seq("The MIT License (MIT)" -> URI.create("https://opensource.org/licenses/MIT").toURL), + developers := List( + Developer( + "dimafeng", + "Dmitry Fedosov", + "dimafeng@gmail.com", + url("http://dimafeng.com") + ) + ), ThisBuild / organization := "com.dimafeng", Global / parallelExecution := false, diff --git a/project/Plugins.sbt b/project/Plugins.sbt index bfba919..0ea5af2 100644 --- a/project/Plugins.sbt +++ b/project/Plugins.sbt @@ -2,3 +2,4 @@ addSbtPlugin("org.xerial.sbt" % "sbt-sonatype" % "3.12.2") addSbtPlugin("com.github.sbt" % "sbt-pgp" % "2.3.0") addSbtPlugin("com.github.sbt" % "sbt-release" % "1.1.0") addSbtPlugin("org.scalastyle" %% "scalastyle-sbt-plugin" % "1.0.0") +addSbtPlugin("com.github.sbt" % "sbt-ci-release" % "1.5.12")