This repository was archived by the owner on Nov 7, 2020. It is now read-only.
File tree 4 files changed +100
-12
lines changed
4 files changed +100
-12
lines changed Original file line number Diff line number Diff line change
1
+ name : Build and Test (Go)
2
+
3
+ on :
4
+ push :
5
+ branches : [ master ]
6
+ pull_request :
7
+ branches : [ master ]
8
+
9
+ jobs :
10
+
11
+ build :
12
+ name : Build
13
+ runs-on : ubuntu-latest
14
+ steps :
15
+
16
+ - name : Set up Go 1.x
17
+ uses : actions/setup-go@v2
18
+ with :
19
+ go-version : ^1.13
20
+ id : go
21
+
22
+ - name : Check out code into the Go module directory
23
+ uses : actions/checkout@v2
24
+
25
+ - name : Cache
26
+
27
+ with :
28
+ path : ~/go/pkg/mod
29
+ key : ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
30
+ restore-keys : |
31
+ ${{ runner.os }}-go-
32
+
33
+ - name : Get dependencies
34
+ run : |
35
+ go get -v -t -d ./...
36
+ if [ -f Gopkg.toml ]; then
37
+ curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
38
+ dep ensure
39
+ fi
40
+
41
+ - name : Build
42
+ run : go build -v .
43
+
44
+ - name : Test
45
+ run : go test -v .
Original file line number Diff line number Diff line change
1
+ name : goreleaser
2
+
3
+ on :
4
+ push :
5
+ tags :
6
+ - ' *'
7
+
8
+ jobs :
9
+ goreleaser :
10
+ runs-on : ubuntu-latest
11
+ steps :
12
+ - name : Checkout
13
+ uses : actions/checkout@v2
14
+
15
+ - name : Unshallow
16
+ run : git fetch --prune --unshallow
17
+
18
+ - name : Set up Go
19
+ uses : actions/setup-go@v2
20
+ with :
21
+ go-version : 1.14
22
+
23
+ - name : Run GoReleaser
24
+ uses : goreleaser/goreleaser-action@v2
25
+ with :
26
+ version : latest
27
+ args : release --rm-dist
28
+ env :
29
+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
Original file line number Diff line number Diff line change
1
+ archives :
2
+ -
3
+ name_template : " {{ .ProjectName }}_{{ .Os }}_{{ .Arch }}"
4
+
5
+ files :
6
+ - none*
7
+
8
+ builds :
9
+ -
10
+ goos :
11
+ - linux
12
+ - darwin
13
+ - windows
14
+
15
+ goarch :
16
+ - " 386"
17
+ - " amd64"
18
+
19
+ checksum :
20
+ name_template : " {{ .ProjectName }}_checksums.txt"
21
+
22
+ release :
23
+ draft : true
24
+
25
+ changelog :
26
+ skip : true
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments