Skip to content

Commit 48bc10f

Browse files
authored
Merge pull request #1 from warpstreamlabs/epot/goreleaser
Add go releaser
2 parents eb7820c + 13db99f commit 48bc10f

2 files changed

Lines changed: 57 additions & 0 deletions

File tree

.github/workflows/release.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
tags:
6+
- "*"
7+
8+
permissions:
9+
contents: write
10+
11+
jobs:
12+
release:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- name: Checkout
16+
uses: actions/checkout@v6
17+
with:
18+
fetch-depth: 0
19+
- name: Go Setup
20+
uses: actions/setup-go@v6
21+
with:
22+
go-version: 1.25
23+
- name: Run Release
24+
uses: goreleaser/goreleaser-action@v6
25+
with:
26+
distribution: goreleaser
27+
version: '~> v2'
28+
args: release --clean
29+
env:
30+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.goreleaser.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
before:
2+
hooks:
3+
- go mod download
4+
builds:
5+
-
6+
main: ./main.go
7+
binary: gobuildcache
8+
ldflags:
9+
- -s -w
10+
goos:
11+
- linux
12+
- darwin
13+
goarch:
14+
- amd64
15+
- arm
16+
- arm64
17+
goarm:
18+
- 5
19+
- 6
20+
- 7
21+
archives:
22+
-
23+
id: gobuildcache
24+
replacements:
25+
darwin: Darwin
26+
linux: Linux
27+
amd64: x86_64

0 commit comments

Comments
 (0)