Skip to content

Commit 23658c8

Browse files
Kamalpreet Kaurclaude
andcommitted
Label the release input Version Type
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
1 parent 10ece45 commit 23658c8

1 file changed

Lines changed: 7 additions & 7 deletions

File tree

‎.github/workflows/publish.yml‎

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ name: publish
33
on:
44
workflow_dispatch:
55
inputs:
6-
bump:
7-
description: Version bump (prerelease publishes <next>-tp.0 to the next dist-tag for testing)
6+
version_type:
7+
description: Version Type
88
required: true
99
default: patch
1010
type: choice
@@ -25,7 +25,7 @@ jobs:
2525
contents: write
2626
id-token: write
2727
env:
28-
BUMP: ${{ inputs.bump }}
28+
VERSION_TYPE: ${{ inputs.version_type }}
2929
steps:
3030
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
3131
with:
@@ -42,17 +42,17 @@ jobs:
4242
run: |
4343
git config user.name "github-actions[bot]"
4444
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
45-
npm version "$BUMP" --preid tp
45+
npm version "$VERSION_TYPE" --preid tp
4646
4747
- name: Publish
48-
run: npm publish --access public --tag "$([ "$BUMP" = prerelease ] && echo next || echo latest)"
48+
run: npm publish --access public --tag "$([ "$VERSION_TYPE" = prerelease ] && echo next || echo latest)"
4949

5050
- name: Push tag
51-
if: inputs.bump == 'prerelease'
51+
if: inputs.version_type == 'prerelease'
5252
run: git push origin "$(git describe --exact-match)"
5353

5454
- name: Push tag and version bump branch
55-
if: inputs.bump != 'prerelease'
55+
if: inputs.version_type != 'prerelease'
5656
run: |
5757
branch="release-$(date +%s)"
5858
git push --follow-tags origin "HEAD:refs/heads/$branch"

0 commit comments

Comments
 (0)