Skip to content

Commit c9d48f6

Browse files
author
cuiko
committed
ci: Add tag-triggered release workflow
Bumping the version, committing, and tagging \`vx.y.z\` should be the entire release ritual — the rest is mechanical. Add \`.github/workflows/release.yml\` that fires on \`v*\` tag pushes, runs \`make dist\` on a macos-14 runner, and creates a GitHub Release with the DMG attached. Release notes use \`gh release create --generate-notes\`, which derives them from PR titles merged since the previous tag (same algorithm as the "Generate release notes" button in the GitHub UI). This removes the manual \`make dist\` + \`gh release create\` steps from the release flow entirely. The workflow needs \`contents: write\` to create the release; no other permissions or secrets are required since \`GITHUB_TOKEN\` covers the release API surface.
1 parent 6da1494 commit c9d48f6

1 file changed

Lines changed: 26 additions & 0 deletions

File tree

.github/workflows/release.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: release
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*'
7+
8+
jobs:
9+
release:
10+
runs-on: macos-14
11+
permissions:
12+
contents: write
13+
steps:
14+
- uses: actions/checkout@v4
15+
- name: Show toolchain
16+
run: swift --version
17+
- name: Build DMG
18+
run: make dist
19+
- name: Create GitHub Release
20+
env:
21+
GH_TOKEN: ${{ github.token }}
22+
run: |
23+
gh release create "${GITHUB_REF_NAME}" \
24+
dist/TermIMS.dmg \
25+
--title "${GITHUB_REF_NAME}" \
26+
--generate-notes

0 commit comments

Comments
 (0)