Skip to content

Commit 4e82627

Browse files
authored
fix: release workflow input as a dropdown (#14)
- Release workflow UX is better with the input as a dropdown instead of a free text box - Removing broken changelog step for now, prefer to manually manage the changelog
1 parent 89f1462 commit 4e82627

File tree

1 file changed

+7
-22
lines changed

1 file changed

+7
-22
lines changed

.github/workflows/release.yml

Lines changed: 7 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,11 @@ on:
55
inputs:
66
bump:
77
description: "Version bump (patch | minor | major)"
8+
type: choice
9+
options:
10+
- patch
11+
- minor
12+
- major
813
required: true
914
default: patch
1015

@@ -39,27 +44,7 @@ jobs:
3944
next="v${major}.${minor}.${patch}"
4045
echo "next=$next" >>"$GITHUB_OUTPUT"
4146
42-
# ───────── 2. update CHANGELOG.md ─────────
43-
- name: Update changelog
44-
shell: bash
45-
run: |
46-
next=${{ steps.version.outputs.next }}
47-
prev=${{ steps.version.outputs.previous }}
48-
49-
{
50-
echo "## $next"
51-
echo
52-
git log "$prev"..HEAD --pretty=format:"- %s"
53-
echo
54-
cat CHANGELOG.md 2>/dev/null || true
55-
} >CHANGELOG.tmp
56-
mv CHANGELOG.tmp CHANGELOG.md
57-
git config user.name "github-actions[bot]"
58-
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
59-
git add CHANGELOG.md
60-
git commit -m "docs: update changelog for $next"
61-
62-
# ───────── 3. tag & push ─────────
47+
# ───────── 2. tag & push ─────────
6348
- name: Tag and push
6449
shell: bash
6550
run: |
@@ -68,7 +53,7 @@ jobs:
6853
git push origin HEAD:main
6954
git push origin "$tag"
7055
71-
# ───────── 4. create & upload release ─────────
56+
# ───────── 3. create & upload release ─────────
7257
- name: Create GitHub release
7358
env:
7459
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)