- ci.yml: gofmt/vet/build/test -race + golangci-lint on push and PR - release.yml: goreleaser on v* tags (tests gate the release) - goreleaser: CGO-free darwin/linux amd64+arm64, version ldflags, conventional-commit changelog, cask published to qf-studio/homebrew-tap (quarantine hook for the unsigned binary)
29 lines
694 B
YAML
29 lines
694 B
YAML
name: release
|
|
|
|
on:
|
|
push:
|
|
tags: ["v*"]
|
|
|
|
permissions:
|
|
contents: write
|
|
|
|
jobs:
|
|
goreleaser:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
with:
|
|
fetch-depth: 0 # full history for the changelog
|
|
- uses: actions/setup-go@v5
|
|
with:
|
|
go-version-file: go.mod
|
|
- run: go test -race ./...
|
|
- uses: goreleaser/goreleaser-action@v6
|
|
with:
|
|
version: "~> v2"
|
|
args: release --clean
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
# PAT with write access to qf-studio/homebrew-tap (formula push).
|
|
HOMEBREW_TAP_GITHUB_TOKEN: ${{ secrets.HOMEBREW_TAP_GITHUB_TOKEN }}
|