File tree 1 file changed +13
-5
lines changed 1 file changed +13
-5
lines changed Original file line number Diff line number Diff line change 9
9
branches :
10
10
- ' master'
11
11
12
+ env :
13
+ # Golang version to use across CI steps
14
+ GOLANG_VERSION : ' 1.17'
15
+
12
16
jobs :
13
17
lint-go :
14
18
name : Lint Go code
15
19
runs-on : ubuntu-latest
16
20
steps :
21
+ - name : Set up Go
22
+ uses : actions/setup-go@v3
23
+ with :
24
+ go-version : ${{ env.GOLANG_VERSION }}
17
25
- name : Checkout code
18
- uses : actions/checkout@v2
26
+ uses : actions/checkout@v3
19
27
- name : Run golangci-lint
20
- uses : golangci/golangci-lint-action@v2
28
+ uses : golangci/golangci-lint-action@v3
21
29
with :
22
- version : v1.38.0
30
+ version : v1.45.2
23
31
args : --timeout 5m
24
32
test :
25
33
runs-on : ubuntu-latest
31
39
key : ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
32
40
restore-keys : |
33
41
${{ runner.os }}-go-
34
- - uses : actions/setup-go@v1
42
+ - uses : actions/setup-go@v3
35
43
with :
36
- go-version : ' 1.17.3 '
44
+ go-version : ${{ env.GOLANG_VERSION }}
37
45
- name : Add ~/go/bin to PATH
38
46
run : |
39
47
echo "/home/runner/go/bin" >> $GITHUB_PATH
You can’t perform that action at this time.
0 commit comments