linters-settings:
  govet:
    enable:
      - fieldalignment
  errcheck:
    # Ignore error checks in test files for common test helpers
    exclude-functions:
      - (io.Closer).Close
      - (*encoding/json.Encoder).Encode
      - (io.Writer).Write

linters:
  enable:
    - errcheck
    - gosec
    - govet
    - gofmt
    - staticcheck
    - unused
    - ineffassign
    - typecheck

issues:
  exclude-dirs:
    - vendor
  # Exclude some linters from running on test files
  exclude-rules:
    - path: _test\.go
      linters:
        - errcheck
        - gosec

run:
  timeout: 5m
  tests: true
