...

Text file src/github.com/alecthomas/chroma/v2/.golangci.yml

Documentation: github.com/alecthomas/chroma/v2

     1run:
     2  tests: true
     3  skip-dirs:
     4    - _examples
     5
     6output:
     7  print-issued-lines: false
     8
     9linters:
    10  enable-all: true
    11  disable:
    12    - maligned
    13    - megacheck
    14    - lll
    15    - gocyclo
    16    - dupl
    17    - gochecknoglobals
    18    - funlen
    19    - godox
    20    - wsl
    21    - gomnd
    22    - gocognit
    23    - goerr113
    24    - nolintlint
    25    - testpackage
    26    - godot
    27    - nestif
    28    - paralleltest
    29    - nlreturn
    30    - cyclop
    31    - exhaustivestruct
    32    - gci
    33    - gofumpt
    34    - errorlint
    35    - exhaustive
    36    - ifshort
    37    - wrapcheck
    38    - stylecheck
    39    - thelper
    40    - nonamedreturns
    41    - revive
    42    - dupword
    43    - exhaustruct
    44    - varnamelen
    45    - forcetypeassert
    46    - ireturn
    47    - maintidx
    48    - govet
    49    - nosnakecase
    50    - testableexamples
    51    - musttag
    52
    53linters-settings:
    54  govet:
    55    check-shadowing: true
    56  gocyclo:
    57    min-complexity: 10
    58  dupl:
    59    threshold: 100
    60  goconst:
    61    min-len: 8
    62    min-occurrences: 3
    63  forbidigo:
    64    #forbid:
    65    #  - (Must)?NewLexer$
    66    exclude_godoc_examples: false
    67
    68
    69issues:
    70  max-per-linter: 0
    71  max-same: 0
    72  exclude-use-default: false
    73  exclude:
    74    # Captured by errcheck.
    75    - '^(G104|G204):'
    76    # Very commonly not checked.
    77    - 'Error return value of .(.*\.Help|.*\.MarkFlagRequired|(os\.)?std(out|err)\..*|.*Close|.*Flush|os\.Remove(All)?|.*printf?|os\.(Un)?Setenv). is not checked'
    78    - 'exported method (.*\.MarshalJSON|.*\.UnmarshalJSON|.*\.EntityURN|.*\.GoString|.*\.Pos) should have comment or be unexported'
    79    - 'composite literal uses unkeyed fields'
    80    - 'declaration of "err" shadows declaration'
    81    - 'should not use dot imports'
    82    - 'Potential file inclusion via variable'
    83    - 'should have comment or be unexported'
    84    - 'comment on exported var .* should be of the form'
    85    - 'at least one file in a package should have a package comment'
    86    - 'string literal contains the Unicode'
    87    - 'methods on the same type should have the same receiver name'
    88    - '_TokenType_name should be _TokenTypeName'
    89    - '`_TokenType_map` should be `_TokenTypeMap`'
    90    - 'rewrite if-else to switch statement'

View as plain text