Skip to content

Commit 4232b48

Browse files
committed
ci(release): support manual tag reruns
1 parent c69bf19 commit 4232b48

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

.github/workflows/release.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,12 @@ on:
44
push:
55
tags:
66
- 'v*'
7+
workflow_dispatch:
8+
inputs:
9+
tag:
10+
description: 'Tag to release (e.g. v0.14.4)'
11+
required: true
12+
type: string
713

814
permissions:
915
contents: write
@@ -21,6 +27,7 @@ jobs:
2127
- uses: actions/checkout@v6
2228
with:
2329
fetch-depth: 0
30+
ref: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.tag || github.ref }}
2431

2532
- uses: actions/setup-go@v6
2633
with:
@@ -30,7 +37,7 @@ jobs:
3037
run: brew install syft
3138

3239
- name: Verify release metadata
33-
run: ./scripts/check-release-version.sh "${GITHUB_REF_NAME}"
40+
run: ./scripts/check-release-version.sh "${{ github.event_name == 'workflow_dispatch' && github.event.inputs.tag || github.ref_name }}"
3441

3542
- name: Run GoReleaser
3643
uses: goreleaser/goreleaser-action@v7

0 commit comments

Comments
 (0)