version: "2"
run:
  issues-exit-code: 1
linters:
  default: none
  enable:
    - bodyclose
    - copyloopvar
    - dogsled
    - dupl
    - errcheck
    - exhaustive
    - gocritic
    - gocyclo
    - gosec
    - govet
    - ineffassign
    - misspell
    - nakedret
    - nolintlint
    - prealloc
    - predeclared
    - revive
    - staticcheck
    - thelper
    - tparallel
    - unconvert
    - unparam
    - whitespace
  settings:
    errcheck:
      check-type-assertions: true
    goconst:
      min-len: 2
      min-occurrences: 3
    gocritic:
      enabled-tags:
        - diagnostic
        - experimental
        - opinionated
        - performance
        - style
    gosec:
      excludes:
        - G115
    govet:
      disable:
        - shadow
    nolintlint:
      require-explanation: true
      require-specific: true
  exclusions:
    generated: lax
    presets:
      - comments
      - common-false-positives
      - legacy
      - std-error-handling
    paths:
      - third_party$
      - builtin$
      - examples$
formatters:
  enable:
    - gofmt
    - goimports
  exclusions:
    generated: lax
    paths:
      - third_party$
      - builtin$
      - examples$
