| Joey Armstrong | 11f5a57 | 2024-01-12 19:11:32 -0500 | [diff] [blame] | 1 | #Copyright 2018-2024 Open Networking Foundation (ONF) and the ONF Contributors |
| Girish Gowdru | 6a80bbd | 2019-07-02 07:36:09 -0700 | [diff] [blame] | 2 | # |
| 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. |
| mgouda | 8654358 | 2025-10-29 20:58:16 +0530 | [diff] [blame] | 14 | version: "2" |
| Girish Gowdru | 6a80bbd | 2019-07-02 07:36:09 -0700 | [diff] [blame] | 15 | |
| mgouda | 8654358 | 2025-10-29 20:58:16 +0530 | [diff] [blame] | 16 | linters: |
| 17 | enable: |
| 18 | #- gocritic |
| 19 | #- gochecknoglobals |
| 20 | #- gochecknoinits |
| 21 | - gocyclo |
| 22 | - govet |
| 23 | - ineffassign |
| 24 | - misspell |
| 25 | - gosec |
| 26 | - errcheck |
| 27 | - whitespace |
| 28 | - staticcheck |
| 29 | - unused |
| 30 | - unparam |
| 31 | exclusions: |
| 32 | rules: |
| 33 | - text: "weak cryptographic primitive" |
| 34 | linters: |
| 35 | - gosec |
| 36 | - path: ".*_test.go" |
| 37 | linters: |
| 38 | - govet |
| 39 | - fieldalignment |
| 40 | - staticcheck |
| 41 | - text: "SA1019:" |
| 42 | linters: |
| 43 | - staticcheck |
| 44 | - text: 'G115: integer overflow conversion' |
| 45 | linters: |
| 46 | - gosec |
| 47 | |
| Girish Gowdru | 6a80bbd | 2019-07-02 07:36:09 -0700 | [diff] [blame] | 48 | linters-settings: |
| 49 | govet: |
| Girish Gowdru | 6a80bbd | 2019-07-02 07:36:09 -0700 | [diff] [blame] | 50 | settings: |
| 51 | printf: |
| 52 | funcs: |
| 53 | - (github.com/golangci/golangci-lint/pkg/logutils.Log).Infof |
| 54 | - (github.com/golangci/golangci-lint/pkg/logutils.Log).Warnf |
| 55 | - (github.com/golangci/golangci-lint/pkg/logutils.Log).Errorf |
| 56 | - (github.com/golangci/golangci-lint/pkg/logutils.Log).Fatalf |
| Akash Kankanala | 041a212 | 2024-10-16 15:49:22 +0530 | [diff] [blame] | 57 | enable: |
| 58 | - shadow |
| 59 | - fieldalignment |
| Girish Gowdru | 6a80bbd | 2019-07-02 07:36:09 -0700 | [diff] [blame] | 60 | golint: |
| 61 | min-confidence: 0 |
| 62 | |
| 63 | gocyclo: |
| Devmalya Paul | 6f063a6 | 2020-02-19 19:19:06 -0500 | [diff] [blame] | 64 | min-complexity: 17 |
| Girish Gowdru | 6a80bbd | 2019-07-02 07:36:09 -0700 | [diff] [blame] | 65 | |
| 66 | misspell: |
| 67 | locale: US |
| 68 | |
| mgouda | 8654358 | 2025-10-29 20:58:16 +0530 | [diff] [blame] | 69 | formatters: |
| Girish Gowdru | 6a80bbd | 2019-07-02 07:36:09 -0700 | [diff] [blame] | 70 | enable: |
| Kent Hagerman | e71b52d | 2020-02-26 11:13:42 -0500 | [diff] [blame] | 71 | - gofmt |
| Akash Kankanala | 041a212 | 2024-10-16 15:49:22 +0530 | [diff] [blame] | 72 | - goimports |
| Girish Gowdru | 6a80bbd | 2019-07-02 07:36:09 -0700 | [diff] [blame] | 73 | run: |
| mgouda | 8654358 | 2025-10-29 20:58:16 +0530 | [diff] [blame] | 74 | modules-download-mode: vendor |