issues:
  exclude:
    - SA5011
  max-issues-per-linter: 0
  max-same-issues: 0
  exclude-rules:
    - path: '(.+)_test\.go'
      linters:
        - unparam
linters:
  enable:
    - errcheck
    - errorlint
    - gocritic
    - gofumpt
    - goimports
    - gosimple
    - govet
    - ineffassign
    - misspell
    - perfsprint
    - staticcheck
    - testifylint
    - thelper
    - unparam
    - unused
    - usestdlibvars
    - whitespace 
linters-settings:
  gocritic:
    disabled-checks:
      - appendAssign
      - assignOp  # Keep it disabled for readability
      - badCond
      - commentFormatting
      - exitAfterDefer
      - ifElseChain
      - mapKey
      - singleCaseSwitch
      - typeSwitchVar
  goimports:
    local-prefixes: github.com/argoproj/argo-cd/v2
  perfsprint:
    # Optimizes even if it requires an int or uint type cast.
    int-conversion: true
    # Optimizes into `err.Error()` even if it is only equivalent for non-nil errors.
    err-error: false
    # Optimizes `fmt.Errorf`.
    errorf: false
    # Optimizes `fmt.Sprintf` with only one argument.
    sprintf1: true
    # Optimizes into strings concatenation.
    strconcat: false
  testifylint:
    enable-all: true
    disable:
      - go-require
run:
  timeout: 50m
