Skip to content
This repository was archived by the owner on Dec 13, 2024. It is now read-only.

Commit 19065db

Browse files
committed
Add goreleaser config to release binaries
1 parent d5b707d commit 19065db

File tree

2 files changed

+66
-0
lines changed

2 files changed

+66
-0
lines changed

.github/workflows/release.yml

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

.goreleaser.yml

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
before:
2+
hooks:
3+
- go mod tidy
4+
builds:
5+
- id: wof-sqlite-index-features
6+
main: ./cmd/wof-sqlite-index-features
7+
binary: wof-sqlite-index-features
8+
env:
9+
- CGO_ENABLED=0
10+
goos:
11+
- linux
12+
- windows
13+
- darwin
14+
universal_binaries:
15+
- replace: true
16+
archives:
17+
-
18+
format: binary
19+
replacements:
20+
386: 32bit
21+
amd64: 64bit
22+
darwin: macos
23+
all: universal
24+
checksum:
25+
name_template: 'checksums.txt'
26+
snapshot:
27+
name_template: "{{ incpatch .Tag }}-next"
28+
changelog:
29+
sort: asc
30+
filters:
31+
exclude:
32+
- '^docs:'
33+
- '^test:'

0 commit comments

Comments
 (0)