Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 30 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: release

on:
push:
tags:
- "v*.*.*"

jobs:
release:
name: release
runs-on: ubuntu-latest

permissions:
contents: read

steps:
- uses: actions/checkout@v5

- uses: actions/setup-go@v5
with:
go-version-file: go.mod

- uses: goreleaser/goreleaser-action@v6
with:
# https://github.com/goreleaser/goreleaser/releases/tag/v2.12.0
version: v2.12.0
args: release --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
HOMEBREW_DEPLOY_KEY: ${{ secrets.HOMEBREW_DEPLOY_KEY }}
38 changes: 38 additions & 0 deletions .goreleaser.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,41 @@ builds:

env:
- CGO_ENABLED=0

archives:
- formats: [tar.gz]
name_template: "{{ .ProjectName }}-{{ .Os }}-{{ .Arch }}"

release:
name_template: "{{ .Tag }} Release"
prerelease: auto

changelog:
disable: true

checksum:
disable: true

homebrew_casks:
- description: Formatter for go.mod and go.work files
homepage: https://github.com/joshdk/modfmt
license: MIT

commit_author:
name: Josh Komoroske
email: jdkomo@gmail.com

hooks:
post:
install: |
if OS.mac?
system_command "/usr/bin/xattr", args: ["-dr", "com.apple.quarantine", "#{staged_path}/{{ .ProjectName }}"]
end

repository:
owner: joshdk
name: homebrew-tap

git:
url: git@github.com:joshdk/homebrew-tap.git
private_key: "{{ .Env.HOMEBREW_DEPLOY_KEY }}"
Loading