Skip to content
Merged
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
17 changes: 9 additions & 8 deletions .golangci.yaml
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
run:
timeout: 5m
go: '1.23.2'

linters:
disable-all: true
enable:
#- containedctx
#- contextcheck
#- depguard
- depguard
- errcheck
#- errchkjson
#- errname
Expand Down Expand Up @@ -39,11 +38,12 @@ linters:

linters-settings:
depguard:
list-type: blacklist
packages:
- k8s.io/kubernetes
packages-with-error-messages:
k8s.io/kubernetes: "do not use k8s.io/kubernetes directly"
rules:
prevent_kubernetes_dependency:
list-mode: lax # allow unless explicitly denied
deny:
- pkg: k8s.io/kubernetes
desc: "do not use k8s.io/kubernetes directly"
errcheck:
exclude-functions:
- encoding/json.Marshal
Expand Down Expand Up @@ -83,12 +83,13 @@ linters-settings:
- performance
- style
gofumpt:
lang-version: "1.23.2"
extra-rules: true
lll:
line-length: 150

issues:
exclude-dirs:
- tilt_modules
exclude-rules:
# ignore errcheck for code under a /test folder
- path: "test/*"
Expand Down
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -110,8 +110,8 @@ vet: ## Run go vet against code
go vet ./...

lint: ## Run linters against code
@go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.62.0
golangci-lint run --out-format=github-actions --timeout 600s --skip-files "tilt_modules"
@go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.62.2
golangci-lint run --out-format=colored-line-number --timeout 600s
@go install github.com/yoheimuta/protolint/cmd/protolint@latest
protolint lint -config_path=.protolint.yaml ./api

Expand Down