Skip to content

Commit 1e44987

Browse files
committed
allow publish for v tags
1 parent f218da7 commit 1e44987

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ jobs:
6868
publish:
6969
name: Publish Artifacts
7070
needs: [build]
71-
if: github.event_name != 'pull_request' && (github.ref == 'refs/heads/master')
71+
if: github.event_name != 'pull_request' && (startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/master')
7272
strategy:
7373
matrix:
7474
os: [ubuntu-latest]

build.sbt

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -126,9 +126,11 @@ Test / parallelExecution := false
126126
ThisBuild / githubWorkflowSbtCommand := "sbt -J-Xmx2G"
127127
ThisBuild / githubWorkflowJavaVersions := Seq(JavaSpec(Zulu, "17"), JavaSpec(Zulu, "21"))
128128
ThisBuild / githubWorkflowTargetBranches := Seq("master")
129-
ThisBuild / githubWorkflowPublishTargetBranches := Seq(
130-
RefPredicate.Equals(Ref.Branch("master"))
131-
)
129+
ThisBuild / githubWorkflowPublishTargetBranches :=
130+
Seq(
131+
RefPredicate.StartsWith(Ref.Tag("v")),
132+
RefPredicate.Equals(Ref.Branch("master"))
133+
)
132134

133135
ThisBuild / githubWorkflowPublish := Seq(
134136
WorkflowStep.Sbt(

0 commit comments

Comments
 (0)