File tree Expand file tree Collapse file tree 3 files changed +44
-8
lines changed Expand file tree Collapse file tree 3 files changed +44
-8
lines changed Original file line number Diff line number Diff line change 11name : golangci-lint
2+
23on :
34 push :
45 branches :
5- - master
6+ - ' ** '
67 pull_request :
8+ branches :
9+ - master
10+
11+ permissions :
12+ contents : read
713
814jobs :
915 golangci :
1319 - name : Checkout code
1420 uses : actions/checkout@v4
1521
16- - name : golangci-lint
17- uses : golangci/golangci-lint-action@v4
22+ - name : Get go version from go.mod
23+ run : |
24+ echo "GO_VERSION=$(grep '^go ' go.mod | cut -d " " -f 2)" >> $GITHUB_ENV
25+
26+ - name : Setup-go
27+ uses : actions/setup-go@v5
28+ with :
29+ go-version : ${{ env.GO_VERSION }}
30+
31+ - name : Run golangci-lint
32+ uses : golangci/golangci-lint-action@v6
33+ with :
34+ version : v1.60.3
Original file line number Diff line number Diff line change 11run :
2- skip-dirs :
3- - benchmarks
2+ timeout : 2m
43
54linters :
65 disable-all : true
76 enable :
87 - dupl
98 - errcheck
10- - exportloopref
9+ - errname
10+ - errorlint
1111 - funlen
12+ - gci
1213 - goconst
1314 - gocritic
1415 - gocyclo
1516 - gofmt
1617 - goimports
18+ - gosec
1719 - gosimple
1820 - govet
1921 - ineffassign
2022 - lll
2123 - misspell
24+ - nolintlint
2225 - prealloc
2326 - revive
2427 - staticcheck
28+ - stylecheck
29+ - thelper
30+ - tparallel
2531 - typecheck
2632 - unconvert
33+ - unparam
34+ - unused
35+ - whitespace
36+
37+ linters-settings :
38+ gosec :
39+ excludes :
40+ - G115
41+ thelper :
42+ test :
43+ begin : false
2744
2845issues :
2946 exclude-rules :
30- # Exclude some linters from running on tests files.
3147 - path : _test\.go
3248 linters :
3349 - errcheck
50+ - funlen
51+
52+ exclude-dirs :
53+ - benchmarks
Original file line number Diff line number Diff line change 77"github.com/reugn/async/internal/util"
88)
99
10- //nolint:funlen
1110func TestValueCompareAndSwap (t * testing.T ) {
1211var value Value
1312swapped := value .CompareAndSwap (1 , 2 )
You can’t perform that action at this time.
0 commit comments