blob: cbda1525af706c7b967314554539951b041f5791 [file] [log] [blame]
Joey Armstrong7a9af442024-01-03 19:26:36 -05001# Copyright 2020-2024 Open Networking Foundation (ONF) and the ONF Contributors
Kent Hagerman812b2572020-01-28 11:57:51 -05002#
3# Licensed under the Apache License, Version 2.0 (the "License");
4# you may not use this file except in compliance with the License.
5# You may obtain a copy of the License at
6#
7# http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS,
11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12# See the License for the specific language governing permissions and
13# limitations under the License.
mgouda2f7349d2025-10-29 10:06:00 +053014version: "2"
15
16linters:
17 enable:
18 #- gochecknoglobals
19 #- gochecknoinits
20 - gocritic
21 - gosec
22 - errcheck
23 - gocyclo
24 - govet
25 - ineffassign
26 - misspell
27 - gosec
28 - staticcheck
29 - unused
30 - unparam
31 exclusions:
32 rules:
33 - path: ".*_test.go"
34 linters:
35 - gocritic
36 - gosec
37 - govet
38 - fieldalignment
39 - unparam
40 - staticcheck
41
42 - text: "ifElseChain:"
43 linters:
44 - gocritic
45 - text: "G115: integer overflow conversion"
46 linters:
47 - gosec
48 - text: "SA1019"
49 linters:
50 - staticcheck
51 - text: "QF1008: could remove embedded field"
52 linters:
53 - staticcheck
Kent Hagerman812b2572020-01-28 11:57:51 -050054
Akash Reddy Kankanala929cc002025-04-08 15:05:21 +053055linters-settings:
56 govet:
57 enable:
58 - shadow
59 - fieldalignment
60 gocyclo:
61 min-complexity: 40
62 misspell:
63 locale: US
64 ignore-words:
65 - cancelled
66 - artefacts
67
mgouda2f7349d2025-10-29 10:06:00 +053068formatters:
69 enable:
70 - gofmt
71 - goimports
72
Kent Hagerman812b2572020-01-28 11:57:51 -050073run:
Kent Hagermandcd4dcc2020-02-25 17:56:17 -050074 modules-download-mode: vendor