git commit -m "feat: add GoReleaser for automated releases and Homebrew integration

- Replace manual GitHub Actions workflow
- Add automated Formula updates to homebrew-sshm tap
- Support pre-releases with auto-detection
- Standardize cross-platform binary distribution"
This commit is contained in:
2025-09-17 14:14:49 +02:00
parent ed6ea2939a
commit 0975ae2fe2
4 changed files with 219 additions and 136 deletions

39
.github/workflows/release.yml vendored Normal file
View File

@@ -0,0 +1,39 @@
name: Release with GoReleaser
on:
push:
tags:
- '*'
permissions:
contents: write
# Required for Homebrew tap updates
issues: write
pull-requests: write
jobs:
goreleaser:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
# Fetch full history for changelog generation
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '1.23'
cache: true
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v6
with:
distribution: goreleaser
version: '~> v2'
args: release --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# Token for updating Homebrew tap (create this secret in your repo settings)
HOMEBREW_TAP_GITHUB_TOKEN: ${{ secrets.HOMEBREW_TAP_GITHUB_TOKEN }}