|
1 |
| -# Documentation reference https://github.com/golangci/golangci-lint/blob/v1.55.2/.golangci.reference.yml |
| 1 | +version: "2" |
2 | 2 | run:
|
3 |
| - skip-dirs-use-default: false |
4 | 3 | modules-download-mode: readonly
|
5 | 4 | allow-parallel-runners: false
|
6 |
| - |
7 |
| -output: |
8 |
| - format: colored-line-number |
9 |
| - print-issued-lines: true |
10 |
| - print-linter-name: true |
11 |
| - uniq-by-line: true |
12 |
| - sort-results: true |
13 |
| - |
14 |
| -linters-settings: |
15 |
| - dogsled: |
16 |
| - max-blank-identifiers: 2 |
17 |
| - errcheck: |
18 |
| - check-type-assertions: true |
19 |
| - check-blank: true |
20 |
| - gci: |
21 |
| - sections: |
22 |
| - - standard |
23 |
| - - default |
24 |
| - - prefix(github.com/openshift/oadp-operator) |
25 |
| - goconst: |
26 |
| - min-len: 3 |
27 |
| - min-occurrences: 5 |
28 |
| - gofmt: |
29 |
| - simplify: true |
30 |
| - goheader: |
31 |
| - # copy from ./hack/boilerplate.go.txt |
32 |
| - template: |- |
33 |
| - Copyright 2021. |
34 |
| -
|
35 |
| - Licensed under the Apache License, Version 2.0 (the "License"); |
36 |
| - you may not use this file except in compliance with the License. |
37 |
| - You may obtain a copy of the License at |
38 |
| -
|
39 |
| - http://www.apache.org/licenses/LICENSE-2.0 |
40 |
| -
|
41 |
| - Unless required by applicable law or agreed to in writing, software |
42 |
| - distributed under the License is distributed on an "AS IS" BASIS, |
43 |
| - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
44 |
| - See the License for the specific language governing permissions and |
45 |
| - limitations under the License. |
46 |
| - govet: |
47 |
| - enable-all: true |
48 |
| - misspell: |
49 |
| - locale: US |
50 |
| - nakedret: |
51 |
| - max-func-lines: 30 |
52 |
| - nolintlint: |
53 |
| - allow-unused: false |
54 |
| - allow-no-explanation: [] |
55 |
| - require-explanation: true |
56 |
| - require-specific: true |
57 |
| - revive: |
58 |
| - # TODO enable! |
59 |
| - # enable-all-rules: true |
60 |
| - rules: |
61 |
| - - name: line-length-limit |
62 |
| - disabled: true |
63 |
| - # TODO delete after |
64 |
| - - name: blank-imports |
65 |
| - - name: dot-imports |
66 |
| - - name: duplicated-imports |
67 |
| - - name: import-alias-naming |
68 |
| - - name: import-shadowing |
69 |
| - - name: redundant-import-alias |
70 |
| - unparam: |
71 |
| - check-exported: true |
72 |
| - |
73 | 5 | linters:
|
74 |
| - disable-all: true |
75 |
| - # TODO enable commented ones |
| 6 | + default: none |
76 | 7 | enable:
|
77 | 8 | - asasalint
|
78 | 9 | - asciicheck
|
79 | 10 | - bidichk
|
80 |
| - # - bodyclose |
81 | 11 | - dogsled
|
82 |
| - # - dupword |
83 |
| - # - durationcheck |
84 |
| - # - errcheck |
85 | 12 | - errchkjson
|
86 |
| - - exportloopref |
87 |
| - - gci |
88 |
| - # - ginkgolinter |
89 |
| - # - goconst |
90 |
| - - gofmt |
91 |
| - # - goheader |
92 | 13 | - goprintffuncname
|
93 |
| - # - gosec |
94 |
| - # - gosimple |
95 |
| - # - govet |
96 |
| - # - ineffassign |
97 | 14 | - loggercheck
|
98 |
| - # - misspell |
99 | 15 | - nakedret
|
100 |
| - # - nilerr |
101 |
| - # - noctx |
102 | 16 | - nolintlint
|
103 | 17 | - nosprintfhostport
|
104 | 18 | - revive
|
105 |
| - # - staticcheck |
106 |
| - # - stylecheck |
107 |
| - # - unconvert |
108 | 19 | - unparam
|
109 |
| - # - unused |
110 | 20 | - usestdlibvars
|
111 |
| - fast: false |
| 21 | + settings: |
| 22 | + dogsled: |
| 23 | + max-blank-identifiers: 2 |
| 24 | + errcheck: |
| 25 | + check-type-assertions: true |
| 26 | + check-blank: true |
| 27 | + goconst: |
| 28 | + min-len: 3 |
| 29 | + min-occurrences: 5 |
| 30 | + goheader: |
| 31 | + template: |- |
| 32 | + Copyright 2021. |
| 33 | +
|
| 34 | + Licensed under the Apache License, Version 2.0 (the "License"); |
| 35 | + you may not use this file except in compliance with the License. |
| 36 | + You may obtain a copy of the License at |
112 | 37 |
|
| 38 | + http://www.apache.org/licenses/LICENSE-2.0 |
| 39 | +
|
| 40 | + Unless required by applicable law or agreed to in writing, software |
| 41 | + distributed under the License is distributed on an "AS IS" BASIS, |
| 42 | + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 43 | + See the License for the specific language governing permissions and |
| 44 | + limitations under the License. |
| 45 | + govet: |
| 46 | + enable-all: true |
| 47 | + misspell: |
| 48 | + locale: US |
| 49 | + nakedret: |
| 50 | + max-func-lines: 30 |
| 51 | + nolintlint: |
| 52 | + require-explanation: true |
| 53 | + require-specific: true |
| 54 | + allow-unused: false |
| 55 | + revive: |
| 56 | + rules: |
| 57 | + - name: line-length-limit |
| 58 | + disabled: true |
| 59 | + - name: blank-imports |
| 60 | + - name: dot-imports |
| 61 | + - name: duplicated-imports |
| 62 | + - name: import-alias-naming |
| 63 | + - name: import-shadowing |
| 64 | + - name: redundant-import-alias |
| 65 | + unparam: |
| 66 | + check-exported: true |
| 67 | + exclusions: |
| 68 | + generated: lax |
| 69 | + rules: |
| 70 | + - linters: |
| 71 | + - revive |
| 72 | + text: '^struct-tag: unknown option ''inline'' in JSON tag$' |
| 73 | + - linters: |
| 74 | + - staticcheck |
| 75 | + text: 'ST1000:|ST1020:|ST1021:|ST1022:' |
| 76 | + paths: |
| 77 | + - third_party$ |
| 78 | + - builtin$ |
| 79 | + - examples$ |
113 | 80 | issues:
|
114 |
| - exclude-use-default: false |
115 |
| - exclude-rules: |
116 |
| - - linters: |
117 |
| - - revive |
118 |
| - text: "^struct-tag: unknown option 'inline' in JSON tag$" |
119 |
| - - linters: |
120 |
| - - stylecheck |
121 |
| - text: "ST1000:|ST1020:|ST1021:|ST1022:" |
122 | 81 | max-issues-per-linter: 0
|
123 | 82 | max-same-issues: 0
|
124 |
| - |
125 | 83 | severity:
|
126 |
| - default-severity: error |
127 |
| - case-sensitive: false |
| 84 | + default: error |
| 85 | +formatters: |
| 86 | + enable: |
| 87 | + - gci |
| 88 | + - gofmt |
| 89 | + settings: |
| 90 | + gci: |
| 91 | + sections: |
| 92 | + - standard |
| 93 | + - default |
| 94 | + - prefix(github.com/openshift/oadp-operator) |
| 95 | + gofmt: |
| 96 | + simplify: true |
| 97 | + exclusions: |
| 98 | + generated: lax |
| 99 | + paths: |
| 100 | + - third_party$ |
| 101 | + - builtin$ |
| 102 | + - examples$ |
0 commit comments