summaryrefslogtreecommitdiffstats
path: root/.golangci.yml
blob: 3a8e66bc3b496f96ec70d974d6a5300984cd6056 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
linters:
  disable:
    - structcheck # gives false positives
  enable:
    - gofumpt
    - thelper
    - goimports
    - tparallel
    - wastedassign
    - exportloopref
    - unparam
    - prealloc
    - unconvert
    - exhaustive
    - makezero
    - nakedret
    - copyloopvar
  fast: false

linters-settings:
  copyloopvar:
    # Check all assigning the loop variable to another variable.
    # Default: false
    # If true, an assignment like `a := x` will be detected as an error.
    check-alias: true
  exhaustive:
    default-signifies-exhaustive: true
  staticcheck:
    # SA1019 is for checking that we're not using fields marked as deprecated
    # in a comment. It decides this in a loose way so I'm silencing it. Also because
    # it's tripping on our own structs.
    checks: ["all", "-SA1019"]
  nakedret:
    # the gods will judge me but I just don't like naked returns at all
    max-func-lines: 0

run:
  go: '1.22'
  timeout: 10m