File tree 3 files changed +27
-14
lines changed
3 files changed +27
-14
lines changed Original file line number Diff line number Diff line change @@ -44,27 +44,30 @@ jobs:
44
44
- name : Install dependencies
45
45
run : |
46
46
go version
47
- go install golang.org/x/lint/golint@latest
48
47
go get -t -v ./...
49
48
50
49
# Build project
51
50
- name : Build project
52
51
run : go build ./...
53
52
54
- # Run go vet & golint
53
+ # Run go vet
55
54
- name : Run go vet
56
55
run : go vet ./...
57
- - name : Run golint
58
- run : golint ./...
59
56
57
+ # Run staticcheck
58
+ - name : Run staticcheck
59
+
60
+ with :
61
+ version : latest
62
+ install-go : false
63
+
60
64
# Run tests
61
65
- name : Run tests
62
66
run : go test -race -coverprofile=coverage.txt -covermode=atomic ./...
63
67
64
- # # Upload coverage report to Codecov
65
- # - name: Report to Codecov
66
-
68
+ # - name: Upload coverage reports to Codecov
69
+ # uses: codecov/codecov-action@v5
67
70
# with:
68
- # file: ./coverage.txt
69
- # # fail_ci_if_error: true # optional (default = false)
70
-
71
+ # token: ${{ secrets.CODECOV_TOKEN }}
72
+ # files: ./coverprofile.out
73
+ # # fail_ci_if_error: true # optional (default = false)
Original file line number Diff line number Diff line change 8
8
runs-on : ubuntu-latest
9
9
steps :
10
10
- name : Checkout repository
11
- uses : actions/checkout@v2
11
+ uses : actions/checkout@v4
12
12
with :
13
13
fetch-depth : 0
14
14
15
+ - name : Install Go
16
+ uses : actions/setup-go@v5
17
+ with :
18
+ go-version-file : ' go.mod'
19
+
15
20
- name : Install cross-compilers
16
21
run : sudo apt-get install gcc-mingw-w64 gcc-aarch64-linux-gnu gcc-arm-linux-gnueabi
17
22
18
23
- name : Run GoReleaser
19
- uses : goreleaser/goreleaser-action@v2
24
+ uses : goreleaser/goreleaser-action@v6
20
25
with :
21
26
version : latest
22
27
args : release --rm-dist --snapshot --skip-publish
Original file line number Diff line number Diff line change @@ -10,15 +10,20 @@ jobs:
10
10
runs-on : ubuntu-latest
11
11
steps :
12
12
- name : Checkout repository
13
- uses : actions/checkout@v2
13
+ uses : actions/checkout@v4
14
14
with :
15
15
fetch-depth : 0
16
16
17
+ - name : Install Go
18
+ uses : actions/setup-go@v5
19
+ with :
20
+ go-version-file : ' stable'
21
+
17
22
- name : Install cross-compilers
18
23
run : sudo apt-get install gcc-mingw-w64 gcc-aarch64-linux-gnu gcc-arm-linux-gnueabi
19
24
20
25
- name : Run GoReleaser
21
- uses : goreleaser/goreleaser-action@v2
26
+ uses : goreleaser/goreleaser-action@v6
22
27
with :
23
28
version : latest
24
29
args : release --rm-dist
You can’t perform that action at this time.
0 commit comments