Skip to content

chore(deps): update golangci/golangci-lint-action action to v8 #190

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,5 @@ jobs:
run: make build
- name: Unit Tests
run: make test
- uses: golangci/golangci-lint-action@v6
- uses: golangci/golangci-lint-action@v8
name: Linting
164 changes: 114 additions & 50 deletions .golangci.yml
Original file line number Diff line number Diff line change
@@ -1,69 +1,133 @@
version: "2"
run:
concurrency: 8
timeout: 10m
concurrency: 16
go: "1.24"
modules-download-mode: mod
issues-exit-code: 1
tests: true
modules-download-mode: mod
allow-parallel-runners: true
go: '1.24'

output:
print-issued-lines: true
print-linter-name: true
sort-results: true

issues:
max-same-issues: 1
max-issues-per-linter: 10
exclude:
- Error return value of `.*.Unlock` is not checked
- Error return value of `.*.Completed` is not checked
linters:
disable-all: true
enable:
- asasalint
- bidichk
- errcheck
- govet
- bodyclose
- ineffassign
- unused
- durationcheck
- goheader
- goimports
- misspell
- gofumpt
- gosimple
- staticcheck
- decorder
- lll
- durationcheck
- errcheck
- errorlint
- gocritic
- gocyclo
- gomodguard
- govet
- ineffassign
- lll
- makezero
- misspell
- nilerr
- prealloc
- predeclared
- revive
- staticcheck
- thelper
- tparallel
- typecheck
- unused
- gomodguard
- gocyclo
- nilerr
- makezero
- wastedassign
- prealloc

- forbidigo
- gomoddirectives
- usestdlibvars
- usetesting
- unconvert

linters-settings:
govet:
settings:
shadow:
strict: true
enable-all: true
gocyclo:
min-complexity: 50
lll:
line-length: 180
gofumpt:
extra-rules: true
goimports:
local-prefixes: github.com/scylladb/scylla-bench
settings:
unconvert:
fast-math: true
safe: true
usetesting:
os-create-temp: true
os-mkdir-temp: true
os-setenv: true
os-temp-dir: true
os-chdir: true
context-background: true
context-todo: true
usestdlibvars:
http-method: true
http-status-code: true
time-weekday: true
time-month: true
time-layout: true
crypto-hash: true
default-rpc-path: true
sql-isolation-level: true
tls-signature-scheme: true
constant-kind: true
gomoddirectives:
replace-local: true
retract-allow-no-explanation: true
exclude-forbidden: true
toolchain-forbidden: true
go-debug-forbidden: true
go-version-pattern: '1\.24(\.\d+)?'
replace-allow-list:
- github.com/gocql/gocql
forbidigo:
analyze-types: true
forbid:
- pattern: ^print(ln)?$
msg: "Use log package instead of fmt"
gocyclo:
min-complexity: 20
govet:
enable-all: true
settings:
shadow:
strict: true
lll:
line-length: 180
exclusions:
generated: lax
presets:
- comments
- common-false-positives
- legacy
- std-error-handling
rules:
- path: (.+)\.go$
text: Error return value of `.*.Unlock` is not checked
- path: (.+)\.go$
text: Error return value of `.*.Completed` is not checked
paths:
- third_party$
- builtin$
- examples$
issues:
max-issues-per-linter: 1000
max-same-issues: 100
uniq-by-line: true
formatters:
enable:
- gofumpt
- goimports
- gci
- golines
settings:
gofumpt:
extra-rules: true
goimports:
local-prefixes:
- github.com/scylladb/scylla-bench
gci:
sections:
- standard
- default
- prefix(github.com/scylladb/scylla-bench)
no-inline-comments: true
golines:
max-len: 180
shorten-comments: true
exclusions:
generated: lax
paths:
- third_party$
- builtin$
- examples$
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ endif

.PHONY: fmt
fmt:
@go tool gofumpt -w -extra .
@go tool golangci-lint fmt

.PHONY: test
test:
Expand Down
Loading
Loading