Skip to content

Commit e5aa02b

Browse files
committed
ci: github action
1 parent 911168c commit e5aa02b

2 files changed

Lines changed: 52 additions & 0 deletions

File tree

.github/workflows/release.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: GoReleaser
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*' # 'v'로 시작하는 태그가 푸시될 때만 실행
7+
8+
jobs:
9+
goreleaser:
10+
runs-on: ubuntu-latest
11+
permissions:
12+
contents: write
13+
steps:
14+
- name: Checkout
15+
uses: actions/checkout@v4
16+
with:
17+
fetch-depth: 0
18+
fetch-tags: true
19+
20+
- name: Set up Go
21+
uses: actions/setup-go@v4
22+
with:
23+
go-version: '1.24'
24+
25+
- name: Run GoReleaser
26+
uses: goreleaser/goreleaser-action@v5
27+
with:
28+
version: latest
29+
args: release --clean
30+
env:
31+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.goreleaser.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
builds:
2+
- env:
3+
- CGO_ENABLED=0
4+
goos:
5+
- linux
6+
- windows
7+
- darwin
8+
goarch:
9+
- amd64
10+
- arm64
11+
archives:
12+
- format: tar.gz
13+
format_overrides:
14+
- goos: windows
15+
format: zip
16+
checksum:
17+
name_template: 'checksums.txt'
18+
snapshot:
19+
name_template: "{{ incpatch .Version }}-next"
20+
changelog:
21+
disable: true

0 commit comments

Comments
 (0)