File tree 4 files changed +78
-73
lines changed
4 files changed +78
-73
lines changed Original file line number Diff line number Diff line change 11
11
runs-on : ubuntu-latest
12
12
strategy :
13
13
matrix :
14
- go : ['1.22', '1.23' ]
14
+ go : [oldstable, stable ]
15
15
steps :
16
16
- uses : actions/checkout@v4
17
17
- name : Set up Go
Original file line number Diff line number Diff line change 15
15
- name : Set up Go
16
16
uses : actions/setup-go@v5
17
17
with :
18
- go-version : ' 1.23 '
18
+ go-version : stable
19
19
20
20
- name : Run golangci-lint
21
- uses : golangci/golangci-lint-action@v6.1.1
21
+ uses : golangci/golangci-lint-action@v7
22
22
with :
23
23
version : latest
Original file line number Diff line number Diff line change 12
12
- name : Install Go
13
13
uses : actions/setup-go@v5
14
14
with :
15
- go-version : 1.23
15
+ go-version : stable
16
16
- name : Unshallow
17
17
run : git fetch --prune --unshallow
18
18
- name : Create release
Original file line number Diff line number Diff line change 1
- linters-settings :
2
- dupl :
3
- threshold : 100
4
- funlen :
5
- lines : 100
6
- statements : 50
7
- goconst :
8
- min-len : 2
9
- min-occurrences : 3
10
- gocritic :
11
- enabled-tags :
12
- - diagnostic
13
- - experimental
14
- - opinionated
15
- - performance
16
- - style
17
- disabled-checks :
18
- - whyNoLint
19
- gocyclo :
20
- min-complexity : 15
21
- goimports :
22
- local-prefixes : github.com/timonwong/loggercheck
23
- mnd :
24
- # don't include the "operation" and "assign"
25
- checks :
26
- - argument
27
- - case
28
- - condition
29
- - return
30
- ignored-numbers :
31
- - ' 0'
32
- - ' 1'
33
- - ' 2'
34
- - ' 3'
35
- ignored-functions :
36
- - strings.SplitN
37
- - strconv.ParseInt
38
- govet :
39
- shadow : true
40
- lll :
41
- line-length : 140
42
- misspell :
43
- locale : US
44
- nolintlint :
45
- allow-unused : false # report any unused nolint directives
46
- require-explanation : false # don't require an explanation for nolint directives
47
- require-specific : false # don't require nolint directives to be specific about which linter is being skipped
1
+ version : " 2"
2
+
3
+ formatters :
4
+ enable :
5
+ - gofumpt
6
+ - goimports
7
+ settings :
8
+ goimports :
9
+ local-prefixes :
10
+ - github.com/timonwong/loggercheck
11
+
48
12
linters :
49
- disable-all : true
13
+ default : none
50
14
enable :
51
15
- bodyclose
16
+ - copyloopvar
52
17
- dogsled
53
18
- dupl
54
19
- errcheck
55
- - copyloopvar
56
20
- funlen
57
21
- gochecknoinits
58
22
- goconst
59
23
- gocritic
60
24
- gocyclo
61
- - gofumpt
62
- - goimports
63
- - mnd
64
25
- goprintffuncname
65
26
- gosec
66
- - gosimple
67
27
- govet
68
28
- ineffassign
69
29
- lll
70
30
- misspell
31
+ - mnd
71
32
- nakedret
72
33
- noctx
73
34
- nolintlint
74
35
- revive
75
36
- staticcheck
76
- - stylecheck
77
- - typecheck
78
37
- unconvert
79
38
- unparam
80
39
- unused
81
40
- whitespace
82
41
83
- issues :
84
- # Excluding configuration per-path, per-linter, per-text and per-source
85
- exclude-rules :
86
- - path : _test\.go
87
- linters :
88
- - mnd
89
- - path : internal/checkers/printf/printf.go
90
- linters :
91
- - gocritic
92
- exclude-dirs :
93
- - testdata
42
+ settings :
43
+ dupl :
44
+ threshold : 100
45
+ funlen :
46
+ lines : 100
47
+ statements : 50
48
+ goconst :
49
+ min-len : 2
50
+ min-occurrences : 3
51
+ gocritic :
52
+ disabled-checks :
53
+ - whyNoLint
54
+ enabled-tags :
55
+ - diagnostic
56
+ - experimental
57
+ - opinionated
58
+ - performance
59
+ - style
60
+ gocyclo :
61
+ min-complexity : 15
62
+ govet :
63
+ enable :
64
+ - shadow
65
+ lll :
66
+ line-length : 140
67
+ misspell :
68
+ locale : US
69
+ mnd :
70
+ # don't include the "operation" and "assign"
71
+ checks :
72
+ - argument
73
+ - case
74
+ - condition
75
+ - return
76
+ ignored-numbers :
77
+ - " 0"
78
+ - " 1"
79
+ - " 2"
80
+ - " 3"
81
+ ignored-functions :
82
+ - strings.SplitN
83
+ - strconv.ParseInt
84
+ nolintlint :
85
+ require-explanation : false # don't require an explanation for nolint directives
86
+ require-specific : false # don't require nolint directives to be specific about which linter is being skipped
87
+ allow-unused : false # report any unused nolint directives
94
88
95
- run :
96
- timeout : 5m
97
- go : ' 1.23'
89
+ exclusions :
90
+ presets :
91
+ - comments
92
+ - common-false-positives
93
+ - legacy
94
+ - std-error-handling
95
+ # Excluding configuration per-path, per-linter, per-text and per-source
96
+ rules :
97
+ - linters :
98
+ - mnd
99
+ path : _test\.go
100
+ - linters :
101
+ - gocritic
102
+ path : internal/checkers/printf/printf.go
You can’t perform that action at this time.
0 commit comments