| 1 |
formatters: |
| 2 |
enable: |
| 3 |
- gci |
| 4 |
- gofumpt |
| 5 |
settings: |
| 6 |
gci: |
| 7 |
sections: |
| 8 |
- standard |
| 9 |
- default |
| 10 |
- prefix(github.com/prometheus/otlptranslator) |
| 11 |
gofumpt: |
| 12 |
extra-rules: true |
| 13 |
issues: |
| 14 |
max-issues-per-linter: 0 |
| 15 |
max-same-issues: 0 |
| 16 |
linters: |
| 17 |
|
| 18 |
enable: |
| 19 |
- depguard |
| 20 |
- errorlint |
| 21 |
- exptostd |
| 22 |
- gocritic |
| 23 |
- godot |
| 24 |
- loggercheck |
| 25 |
- misspell |
| 26 |
- nilnesserr |
| 27 |
|
| 28 |
|
| 29 |
- perfsprint |
| 30 |
- predeclared |
| 31 |
- revive |
| 32 |
- sloglint |
| 33 |
- testifylint |
| 34 |
- unconvert |
| 35 |
- unused |
| 36 |
- usestdlibvars |
| 37 |
- whitespace |
| 38 |
settings: |
| 39 |
depguard: |
| 40 |
rules: |
| 41 |
main: |
| 42 |
deny: |
| 43 |
- pkg: sync/atomic |
| 44 |
desc: Use go.uber.org/atomic instead of sync/atomic |
| 45 |
- pkg: github.com/stretchr/testify/assert |
| 46 |
desc: Use github.com/stretchr/testify/require instead of github.com/stretchr/testify/assert |
| 47 |
- pkg: io/ioutil |
| 48 |
desc: Use corresponding 'os' or 'io' functions instead. |
| 49 |
- pkg: github.com/pkg/errors |
| 50 |
desc: Use 'errors' or 'fmt' instead of github.com/pkg/errors |
| 51 |
- pkg: golang.org/x/exp/slices |
| 52 |
desc: Use 'slices' instead. |
| 53 |
perfsprint: |
| 54 |
|
| 55 |
errorf: true |
| 56 |
revive: |
| 57 |
|
| 58 |
|
| 59 |
rules: |
| 60 |
|
| 61 |
- name: blank-imports |
| 62 |
- name: comment-spacings |
| 63 |
- name: context-as-argument |
| 64 |
arguments: |
| 65 |
|
| 66 |
- allowTypesBefore: '*testing.T,testing.TB' |
| 67 |
- name: context-keys-type |
| 68 |
- name: dot-imports |
| 69 |
- name: early-return |
| 70 |
arguments: |
| 71 |
- preserveScope |
| 72 |
|
| 73 |
|
| 74 |
- name: empty-block |
| 75 |
disabled: true |
| 76 |
- name: error-naming |
| 77 |
- name: error-return |
| 78 |
- name: error-strings |
| 79 |
- name: errorf |
| 80 |
- name: exported |
| 81 |
- name: increment-decrement |
| 82 |
- name: indent-error-flow |
| 83 |
arguments: |
| 84 |
- preserveScope |
| 85 |
- name: range |
| 86 |
- name: receiver-naming |
| 87 |
- name: redefines-builtin-id |
| 88 |
- name: superfluous-else |
| 89 |
arguments: |
| 90 |
- preserveScope |
| 91 |
- name: time-naming |
| 92 |
- name: unexported-return |
| 93 |
- name: unreachable-code |
| 94 |
- name: unused-parameter |
| 95 |
- name: var-declaration |
| 96 |
- name: var-naming |
| 97 |
testifylint: |
| 98 |
disable: |
| 99 |
- float-compare |
| 100 |
- go-require |
| 101 |
enable-all: true |
| 102 |
run: |
| 103 |
timeout: 15m |
| 104 |
version: "2" |