|
| 1 | +run: |
| 2 | + timeout: 5m |
| 3 | + go: '1.19' |
| 4 | + skip-dirs: |
| 5 | + - vendor/ |
| 6 | + |
| 7 | +linters: |
| 8 | + disable-all: true |
| 9 | + enable: |
| 10 | + - bodyclose # checks whether HTTP response body is closed successfully |
| 11 | + - deadcode # Finds unused code |
| 12 | + - gci # Gci controls golang package import order and makes it always deterministic. |
| 13 | + - dogsled # Checks assignments with too many blank identifiers (e.g. x, , , _, := f()) |
| 14 | + - dupl # Tool for code clone detection |
| 15 | + - errcheck # checks whether Err of rows is checked successfully |
| 16 | + - goconst # Finds repeated strings that could be replaced by a constant |
| 17 | + - gocritic # check for bugs, performance and style issues. |
| 18 | + - gocyclo # Computes and checks the cyclomatic complexity of functions |
| 19 | + - gofmt |
| 20 | + - goimports # In addition to fixing imports, goimports also formats your code in the same style as gofmt. |
| 21 | + - goprintffuncname # Checks that printf-like functions are named with f at the end |
| 22 | + - gosec # Inspects source code for security problems |
| 23 | + - gosimple # Linter for Go source code that specializes in simplifying code |
| 24 | + - govet |
| 25 | + - ineffassign # Detects when assignments to existing variables are not used |
| 26 | + - nakedret # Finds naked returns in functions |
| 27 | + - stylecheck # Stylecheck is a replacement for golint |
| 28 | + - typecheck # Like the front-end of a Go compiler, parses and type-checks Go code |
| 29 | + - unparam # Reports unused function parameters |
| 30 | + - unused # Checks Go code for unused constants, variables, functions and types |
| 31 | + - varcheck # Finds unused global variables and constants |
| 32 | + - whitespace # Tool for detection of leading and trailing whitespace |
| 33 | + |
| 34 | +issues: |
| 35 | + # List of regexps of issue texts to exclude. |
| 36 | + exclude-rules: |
| 37 | + - linters: |
| 38 | + - gosec |
| 39 | + text: "G306" |
| 40 | + |
| 41 | +linters-settings: |
| 42 | + gci: |
| 43 | + # Section configuration to compare against. |
| 44 | + # Section names are case-insensitive and may contain parameters in (). |
| 45 | + # Default: ["standard", "default"] |
| 46 | + sections: |
| 47 | + - standard # Captures all standard packages if they do not match another section. |
| 48 | + - default # Contains all imports that could not be matched to another section type. |
| 49 | + - prefix(github.com/gitpod-io/observability) # Groups all imports with the specified Prefix. |
0 commit comments