-
Notifications
You must be signed in to change notification settings - Fork 3
/
publish.sbt
47 lines (36 loc) · 1.31 KB
/
publish.sbt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
ThisBuild / organization := "io.crashbox"
ThisBuild / licenses := Seq(
("Apache 2.0", url("https://www.apache.org/licenses/LICENSE-2.0")))
ThisBuild / homepage := Some(url("https://github.com/jodersky/sbt-gpg"))
ThisBuild / publishTo := sonatypePublishToBundle.value
ThisBuild / versionScheme := Some("early-semver")
ThisBuild / scmInfo := Some(
ScmInfo(
url("https://github.com/jodersky/sbt-gpg"),
"scm:git@github.com:jodersky/sbt-gpg.git"
)
)
ThisBuild / developers := List(
Developer(
id = "jodersky",
name = "Jakob Odersky",
email = "jakob@odersky.com",
url = url("https://crashbox.io")
)
)
ThisBuild / githubWorkflowTargetTags ++= Seq("v*")
ThisBuild / githubWorkflowPublishTargetBranches :=
Seq(RefPredicate.StartsWith(Ref.Tag("v")))
ThisBuild / githubWorkflowPublishPreamble ++= Seq(
WorkflowStep.Run(
List("echo \"$GPG_SECRET_KEY\" | gpg --import"),
name = Some("Import private key"),
env = Map("GPG_SECRET_KEY" -> "${{ secrets.GPG_SECRET_KEY }}")),
WorkflowStep.Run(
List("mv sonatype.proto-sbt sonatype.sbt"),
name = Some("Unlock publication configuration")))
ThisBuild / githubWorkflowPublish := Seq(
WorkflowStep.Sbt(
List("publish", "sonatypeBundleRelease"),
name = Some("Release"),
env = Map("SONATYPE_PASS" -> "${{ secrets.SONATYPE_PASS }}")))