Skip to content

Commit 707a1a2

Browse files
committed
ci: update golangci-lint
1 parent 12b078a commit 707a1a2

File tree

2 files changed

+61
-47
lines changed

2 files changed

+61
-47
lines changed

.github/workflows/build.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@ jobs:
1313
with:
1414
go-version: 1.25.x
1515
- uses: actions/checkout@v4
16-
- uses: golangci/golangci-lint-action@v3
16+
- uses: golangci/golangci-lint-action@v8
1717
with:
18-
version: v1.64.4
18+
version: v2.4.0
1919
test_windows:
2020
if: github.event_name == 'push' || (github.event_name == 'pull_request' && github.repository != github.event.pull_request.head.repo.full_name)
2121
runs-on: windows-latest

.golangci.yml

Lines changed: 59 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -1,47 +1,61 @@
1-
issues:
2-
exclude-dirs:
3-
- example
4-
1+
version: "2"
52
linters:
6-
enable:
7-
- asciicheck
8-
- gci
9-
- godot
10-
- gofmt
11-
- gofumpt
12-
- goimports
13-
- gomodguard
14-
- goprintffuncname
15-
- gosimple
16-
- govet
17-
- misspell
18-
- nakedret
19-
- nolintlint
20-
- sqlclosecheck
21-
- typecheck
22-
- unconvert
23-
- unused
24-
- whitespace
25-
disable:
26-
- errcheck
27-
- revive
28-
- funlen
29-
- gochecknoglobals
30-
- staticcheck
31-
- gocognit
32-
- goconst
33-
- gocyclo
34-
- godox
35-
- lll
36-
- nestif
37-
- nlreturn
38-
- noctx
39-
- testpackage
40-
- wsl
41-
- ineffassign
42-
43-
linters-settings:
44-
gofumpt:
45-
extra-rules: true
3+
enable:
4+
- asciicheck
5+
- godot
6+
- gomodguard
7+
- goprintffuncname
8+
- misspell
9+
- nakedret
10+
- nolintlint
11+
- sqlclosecheck
12+
- unconvert
13+
- whitespace
14+
disable:
15+
- errcheck
16+
- funlen
17+
- gochecknoglobals
18+
- gocognit
19+
- goconst
20+
- gocyclo
21+
- godox
22+
- ineffassign
23+
- lll
24+
- nestif
25+
- nlreturn
26+
- noctx
27+
- revive
28+
- staticcheck
29+
- testpackage
30+
- wsl
31+
settings:
4632
misspell:
47-
locale: US
33+
locale: US
34+
exclusions:
35+
generated: lax
36+
presets:
37+
- comments
38+
- common-false-positives
39+
- legacy
40+
- std-error-handling
41+
paths:
42+
- example
43+
- third_party$
44+
- builtin$
45+
- examples$
46+
formatters:
47+
enable:
48+
- gci
49+
- gofmt
50+
- gofumpt
51+
- goimports
52+
settings:
53+
gofumpt:
54+
extra-rules: true
55+
exclusions:
56+
generated: lax
57+
paths:
58+
- example
59+
- third_party$
60+
- builtin$
61+
- examples$

0 commit comments

Comments
 (0)