2023-08-25 14:09:58 +00:00
|
|
|
run:
|
2024-10-10 16:50:48 +00:00
|
|
|
timeout: 10m
|
2023-08-25 14:09:58 +00:00
|
|
|
|
|
|
|
linters:
|
|
|
|
enable:
|
|
|
|
- contextcheck
|
|
|
|
- gocritic
|
|
|
|
- gofmt
|
|
|
|
- goimports
|
|
|
|
- gosec
|
|
|
|
- gosimple
|
|
|
|
- govet
|
|
|
|
- ineffassign
|
|
|
|
- misspell
|
|
|
|
- staticcheck
|
|
|
|
- unconvert
|
2023-08-28 09:08:36 +00:00
|
|
|
|
2023-12-01 01:10:10 +00:00
|
|
|
linters-settings:
|
|
|
|
goimports:
|
|
|
|
local-prefixes: github.com/NVIDIA/nvidia-container-toolkit
|
|
|
|
|
2023-08-28 09:08:36 +00:00
|
|
|
issues:
|
2024-02-19 10:35:01 +00:00
|
|
|
exclude:
|
|
|
|
# The legacy hook relies on spec.Hooks.Prestart, which is deprecated as of the v1.2.0 OCI runtime spec.
|
|
|
|
- "SA1019:(.+).Prestart is deprecated(.+)"
|
2024-08-22 09:33:59 +00:00
|
|
|
# TODO: We should address each of the following integer overflows.
|
|
|
|
- "G115: integer overflow conversion(.+)"
|
2023-08-28 09:08:36 +00:00
|
|
|
exclude-rules:
|
|
|
|
# Exclude the gocritic dupSubExpr issue for cgo files.
|
|
|
|
- path: internal/dxcore/dxcore.go
|
|
|
|
linters:
|
|
|
|
- gocritic
|
|
|
|
text: dupSubExpr
|
2023-08-30 14:08:10 +00:00
|
|
|
# Exclude the checks for usage of returns to config.Delete(Path) in the crio and containerd config packages.
|
|
|
|
- path: pkg/config/engine/
|
|
|
|
linters:
|
|
|
|
- errcheck
|
|
|
|
text: config.Delete
|
2024-09-24 17:05:14 +00:00
|
|
|
# RENDERD refers to the Render Device and not the past tense of render.
|
|
|
|
- path: .*.go
|
|
|
|
linters:
|
|
|
|
- misspell
|
|
|
|
text: "`RENDERD` is a misspelling of `RENDERED`"
|