Skip to content

Commit ac80792

Browse files
committed
fix ci
1 parent defc50c commit ac80792

File tree

19 files changed

+736
-401
lines changed

19 files changed

+736
-401
lines changed

.github/workflows/release.yml

Lines changed: 28 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2,21 +2,35 @@ name: Release Kafta binaries
22

33
on:
44
push:
5-
branches: [ main ]
6-
pull_request:
7-
branches: [ main ]
5+
tags:
6+
- '*'
87

98
jobs:
10-
release-linux-amd64:
11-
name: release linux/amd64
9+
goreleaser:
1210
runs-on: ubuntu-latest
1311
steps:
14-
- uses: actions/checkout@master
15-
- name: compile and release
16-
uses: ngs/go-release.action@v1.0.2
17-
env:
18-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
19-
GOARCH: amd64
20-
GOOS: linux
21-
EXTRA_FILES: "LICENSE"
22-
CMD_PATH: "./build.sh"
12+
-
13+
name: Checkout
14+
uses: actions/checkout@v2
15+
with:
16+
fetch-depth: 0
17+
-
18+
name: Set up Go
19+
uses: actions/setup-go@v2
20+
with:
21+
go-version: 1.15
22+
-
23+
name: Run GoReleaser
24+
uses: goreleaser/goreleaser-action@v2
25+
with:
26+
distribution: goreleaser
27+
version: latest
28+
args: release --rm-dist
29+
env:
30+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
31+
32+
- name: Upload assets
33+
uses: actions/upload-artifact@v2
34+
with:
35+
name: kafta
36+
path: dist/*

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,3 +27,5 @@
2727

2828
# End of https://www.toptal.com/developers/gitignore/api/go
2929
.vscode/launch.json
30+
31+
dist/

.goreleaser.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
project_name: kafta
2+
before:
3+
hooks:
4+
- go mod tidy
5+
- go generate ./...
6+
builds:
7+
- env:
8+
- CGO_ENABLED=0
9+
goos:
10+
- linux
11+
- windows
12+
- darwin
13+
goarch:
14+
- amd64
15+
- arm64
16+
- arm
17+
- ppc64le
18+
goarm:
19+
- 7
20+
flags:
21+
- -trimpath
22+
ldflags:
23+
- -s -w -X github.com/electric-saw/kafta/internal/version.version={{.Tag}} -X github.com/electric-saw/kafta/internal/version.metadata={{.Branch}} -X github.com/electric-saw/kafta/internal/version.gitCommit={{.ShortCommit}}
24+
main: ./cmd/kafta
25+
archives:
26+
- replacements:
27+
darwin: Darwin
28+
linux: Linux
29+
windows: Windows
30+
386: i386
31+
amd64: x86_64
32+
checksum:
33+
name_template: 'checksums.txt'
34+
snapshot:
35+
name_template: "{{ incpatch .Version }}-next"
36+
changelog:
37+
sort: asc
38+
filters:
39+
exclude:
40+
- '^docs:'
41+
- '^test:'

go.mod

Lines changed: 48 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,55 @@
11
module github.com/electric-saw/kafta
22

3-
go 1.16
3+
go 1.17
44

55
require (
6-
github.com/Shopify/sarama v1.27.0
7-
github.com/Songmu/prompter v0.3.0
6+
github.com/Shopify/sarama v1.30.0
7+
github.com/Songmu/prompter v0.5.0
88
github.com/dustin/go-humanize v1.0.0
9-
github.com/go-openapi/strfmt v0.19.5 // indirect
109
github.com/jedib0t/go-pretty v4.3.0+incompatible
11-
github.com/manifoldco/promptui v0.7.0
12-
github.com/mattn/go-runewidth v0.0.9 // indirect
13-
github.com/riferrei/srclient v0.2.1
14-
github.com/sirupsen/logrus v1.6.0
15-
github.com/spf13/cobra v1.0.0
16-
github.com/tcnksm/go-input v0.0.0-20180404061846-548a7d7a8ee8
17-
github.com/xdg/scram v0.0.0-20180814205039-7eeb5667e42c
18-
gopkg.in/yaml.v3 v3.0.0-20200615113413-eeeca48fe776
19-
k8s.io/cli-runtime v0.19.0
20-
k8s.io/component-base v0.19.0
10+
github.com/liggitt/tabwriter v0.0.0-20181228230101-89fcab3d43de
11+
github.com/manifoldco/promptui v0.8.0
12+
github.com/sirupsen/logrus v1.8.1
13+
github.com/spf13/cobra v1.2.1
14+
github.com/xdg/scram v1.0.3
15+
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b
16+
)
17+
18+
require (
19+
github.com/asaskevich/govalidator v0.0.0-20200907205600-7a23bdc65eef // indirect
20+
github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e // indirect
21+
github.com/davecgh/go-spew v1.1.1 // indirect
22+
github.com/eapache/go-resiliency v1.2.0 // indirect
23+
github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21 // indirect
24+
github.com/eapache/queue v1.1.0 // indirect
25+
github.com/go-openapi/errors v0.19.8 // indirect
26+
github.com/go-openapi/strfmt v0.20.3 // indirect
27+
github.com/go-stack/stack v1.8.0 // indirect
28+
github.com/golang/snappy v0.0.4 // indirect
29+
github.com/hashicorp/go-uuid v1.0.2 // indirect
30+
github.com/inconshreveable/mousetrap v1.0.0 // indirect
31+
github.com/jcmturner/aescts/v2 v2.0.0 // indirect
32+
github.com/jcmturner/dnsutils/v2 v2.0.0 // indirect
33+
github.com/jcmturner/gofork v1.0.0 // indirect
34+
github.com/jcmturner/gokrb5/v8 v8.4.2 // indirect
35+
github.com/jcmturner/rpc/v2 v2.0.3 // indirect
36+
github.com/juju/ansiterm v0.0.0-20180109212912-720a0952cc2a // indirect
37+
github.com/klauspost/compress v1.13.6 // indirect
38+
github.com/lunixbochs/vtclean v0.0.0-20180621232353-2d01aacdc34a // indirect
39+
github.com/mattn/go-colorable v0.0.9 // indirect
40+
github.com/mattn/go-isatty v0.0.12 // indirect
41+
github.com/mattn/go-runewidth v0.0.13 // indirect
42+
github.com/mitchellh/mapstructure v1.4.1 // indirect
43+
github.com/oklog/ulid v1.3.1 // indirect
44+
github.com/pierrec/lz4 v2.6.1+incompatible // indirect
45+
github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 // indirect
46+
github.com/rivo/uniseg v0.2.0 // indirect
47+
github.com/spf13/pflag v1.0.5 // indirect
48+
github.com/xdg/stringprep v1.0.3 // indirect
49+
go.mongodb.org/mongo-driver v1.5.1 // indirect
50+
golang.org/x/crypto v0.0.0-20210920023735-84f357641f63 // indirect
51+
golang.org/x/net v0.0.0-20210917221730-978cfadd31cf // indirect
52+
golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1 // indirect
53+
golang.org/x/term v0.0.0-20210317153231-de623e64d2a6 // indirect
54+
golang.org/x/text v0.3.7 // indirect
2155
)

0 commit comments

Comments
 (0)