Skip to content

Commit 0ad7ba3

Browse files
authored
Add basic ci
1 parent f154c6b commit 0ad7ba3

1 file changed

Lines changed: 29 additions & 0 deletions

File tree

.github/workflows/go.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: build
2+
3+
on:
4+
push:
5+
tags:
6+
- '*'
7+
8+
jobs:
9+
build:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v4
13+
14+
- uses: actions/setup-go@v4
15+
with:
16+
go-version: '1.22'
17+
18+
- name: build
19+
env:
20+
CGO_ENABLED: 0
21+
GOOS: linux
22+
GOARCH: amd64
23+
run: |
24+
go build -buildvcs=false -ldflags="-s -w" -o elect -v ./...
25+
tar czf elect.tar.gz elect
26+
27+
- uses: softprops/action-gh-release@v2
28+
with:
29+
files: ${{ github.workspace }}/elect.tar.gz

0 commit comments

Comments
 (0)