33
33
# it relies on the existence of a go.sum file.
34
34
cache : false
35
35
go-version : " 1.20"
36
- - id : setup-go-critic
37
- run :
go install -v github.com/go-critic/go-critic/cmd/[email protected]
38
- - id : setup staticheck
39
- uses : actions/checkout@v3
40
- with :
41
- fetch-depth : 1
42
- - name : Run staticcheck
43
-
44
- with :
45
- version : " 2022.1.3"
46
- - id : setup-go-sec
47
- uses : actions/checkout@v3
48
- env :
49
- GO111MODULE : on
50
- - name : Run Gosec Security Scanner
51
- uses : securego/gosec@master
52
36
- name : Lookup Go cache directory
53
37
id : go-cache
54
38
run : |
80
64
${{ env.BASE_CACHE_KEY }}
81
65
- name : Setup curl cache
82
66
run : mkdir -p ${{ env.CURL_CACHE_DIR }}
67
+ - name : Install GoCritic
68
+ env :
69
+ PACKAGE_URL : github.com/go-critic/go-critic/cmd/gocritic
70
+ PACKAGE_VERSION : ${{ steps.setup-env.outputs.go-critic-version }}
71
+ run : go install ${PACKAGE_URL}@${PACKAGE_VERSION}
72
+ - name : Install GoSec
73
+ env :
74
+ PACKAGE_URL : github.com/securego/gosec/v2/cmd/gosec
75
+ PACKAGE_VERSION : ${{ steps.setup-env.outputs.gosec-version }}
76
+ run : go install ${PACKAGE_URL}@${PACKAGE_VERSION}
83
77
- name : Install Packer
84
78
env :
85
79
PACKER_VERSION : ${{ steps.setup-env.outputs.packer-version }}
@@ -101,6 +95,11 @@ jobs:
101
95
PACKAGE_URL : mvdan.cc/sh/v3/cmd/shfmt
102
96
PACKAGE_VERSION : ${{ steps.setup-env.outputs.shfmt-version }}
103
97
run : go install ${PACKAGE_URL}@${PACKAGE_VERSION}
98
+ - name : Install Staticcheck
99
+ env :
100
+ PACKAGE_URL : dominikh/staticcheck-action
101
+ PACKAGE_VERSION : ${{ steps.setup-env.outputs.go-staticcheck-version }}
102
+ run : go install ${PACKAGE_URL}@${PACKAGE_VERSION}
104
103
- name : Install Terraform-docs
105
104
env :
106
105
PACKAGE_URL : github.com/terraform-docs/terraform-docs
0 commit comments