File tree Expand file tree Collapse file tree 2 files changed +85
-2
lines changed Expand file tree Collapse file tree 2 files changed +85
-2
lines changed Original file line number Diff line number Diff line change
1
+ name : lint
2
+
3
+ on :
4
+ push :
5
+ branches :
6
+ - main
7
+ - ' release/**'
8
+ pull_request :
9
+
10
+ env :
11
+ GO_VERSION : 1.24.x
12
+ GOTOOLCHAIN : local
13
+
14
+ jobs :
15
+ go :
16
+ timeout-minutes : 5
17
+ name : " ${{ matrix.goos }} | ${{ matrix.canary }}"
18
+ runs-on : " ${{ matrix.os }}"
19
+ defaults :
20
+ run :
21
+ shell : bash
22
+ strategy :
23
+ fail-fast : false
24
+ # Note: technically, `make lint-go-all` will run the linter for all platforns, and could be called on a single instance.
25
+ # The point of running it instead on a matrix here is to verify that the tooling itself is working on the target OS.
26
+ matrix :
27
+ include :
28
+ - os : ubuntu-24.04
29
+ goos : linux
30
+ - os : ubuntu-24.04
31
+ goos : freebsd
32
+ - os : macos-15
33
+ # FIXME: this is currently failing in a non-sensical way, so, running on linux instead...
34
+ # - os: windows-2022
35
+ - os : ubuntu-24.04
36
+ goos : windows
37
+ - os : ubuntu-24.04
38
+ goos : linux
39
+ # This allows the canary script to select any upcoming golang alpha/beta/RC
40
+ canary : go-canary
41
+ steps :
42
+ - uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
43
+ with :
44
+ fetch-depth : 1
45
+ - name : Set GO env
46
+ run : |
47
+ # If canary is specified, get the latest available golang pre-release instead of the major version
48
+ if [ "${{ matrix.canary }}" != "" ]; then
49
+ . ./hack/build-integration-canary.sh
50
+ canary::golang::latest
51
+ fi
52
+ - uses : actions/setup-go@0aaccfd150d50ccaeb58ebd88d36e91967a5f35b # v5.4.0
53
+ with :
54
+ go-version : ${{ env.GO_VERSION }}
55
+ check-latest : true
56
+ - name : install required linters and dev-tools
57
+ run : |
58
+ make install-dev-tools
59
+ - name : golangci-lint
60
+ run : |
61
+ NO_COLOR=true GOOS="${{ matrix.goos }}" make lint-go
62
+ other :
63
+ timeout-minutes : 5
64
+ name : yaml | shell | imports order
65
+ runs-on : ubuntu-24.04
66
+ steps :
67
+ - uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
68
+ with :
69
+ fetch-depth : 1
70
+ - uses : actions/setup-go@0aaccfd150d50ccaeb58ebd88d36e91967a5f35b # v5.4.0
71
+ with :
72
+ go-version : ${{ env.GO_VERSION }}
73
+ check-latest : true
74
+ - name : install required linters and dev-tools
75
+ run : |
76
+ make install-dev-tools
77
+ - name : yaml
78
+ run : make lint-yaml
79
+ - name : shell
80
+ run : make lint-shell
Original file line number Diff line number Diff line change @@ -135,8 +135,9 @@ lint-go-all:
135
135
$(call title, $@ )
136
136
@cd $(MAKEFILE_DIR ) \
137
137
&& GOOS=linux make lint-go \
138
- && GOOS=windows make lint-go \
139
- && GOOS=freebsd make lint-go
138
+ && GOOS=freebsd make lint-go \
139
+ && GOOS=darwin make lint-go \
140
+ && GOOS=windows make lint-go
140
141
$(call footer, $@ )
141
142
142
143
lint-yaml :
@@ -180,6 +181,7 @@ lint-licenses-all:
180
181
@cd $(MAKEFILE_DIR ) \
181
182
&& GOOS=linux make lint-licenses \
182
183
&& GOOS=freebsd make lint-licenses \
184
+ && GOOS=darwin make lint-licenses \
183
185
&& GOOS=windows make lint-licenses
184
186
$(call footer, $@ )
185
187
@@ -197,6 +199,7 @@ fix-go-all:
197
199
@cd $(MAKEFILE_DIR ) \
198
200
&& GOOS=linux make fix-go \
199
201
&& GOOS=freebsd make fix-go \
202
+ && GOOS=darwin make fix-go \
200
203
&& GOOS=windows make fix-go
201
204
$(call footer, $@ )
202
205
You can’t perform that action at this time.
0 commit comments