-
Notifications
You must be signed in to change notification settings - Fork 15
/
.golangci.yml
84 lines (81 loc) · 1.97 KB
/
.golangci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
linters:
# Enable specific linter
enable:
# https://golangci-lint.run/usage/linters/#enabled-by-default
# - errcheck
# - gosimple
# - govet
# - ineffassign
# - staticcheck
# - unused
- gocritic
- gofmt
- goimports
- gosec
- revive
- typecheck
- bodyclose
linters-settings:
staticcheck:
checks:
- all
# Ignore usage of deprecated things, will be removed after frontend resources are using new navigation
- '-SA1019'
gosec:
excludes:
- G115
issues:
exclude-rules:
- path: api/v1alpha1/groupversion_info.go
linters:
- gofmt
- goimports
# Fix found issues (if it's supported by the linter).
# Default: false
# fix: true
# Maximum count of issues with the same text.
# Set to 0 to disable.
# Default: 3
max-same-issues: 20
output:
# The formats used to render issues.
# Formats:
# - `colored-line-number`
# - `line-number`
# - `json`
# - `colored-tab`
# - `tab`
# - `html`
# - `checkstyle`
# - `code-climate`
# - `junit-xml`
# - `github-actions`
# - `teamcity`
# - `sarif`
# Output path can be either `stdout`, `stderr` or path to the file to write to.
#
# For the CLI flag (`--out-format`), multiple formats can be specified by separating them by comma.
# The output can be specified for each of them by separating format name and path by colon symbol.
# Example: "--out-format=checkstyle:report.xml,json:stdout,colored-line-number"
# The CLI flag (`--out-format`) override the configuration file.
#
# Default:
# formats:
# - format: colored-line-number
# path: stdout
# Print lines of code with issue.
# Default: true
# print-issued-lines: false
# Print linter name in the end of issue text.
# Default: true
# print-linter-name: false
# Sort results by the order defined in `sort-order`.
# Default: false
sort-results: true
# Make issues output unique by line.
# Default: true
uniq-by-line: false
run:
# Timeout for analysis, e.g. 30s, 5m.
# Default: 1m
timeout: 5m