forked from go-vikunja/vikunja
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.golangci.yml
More file actions
165 lines (165 loc) · 4.04 KB
/
.golangci.yml
File metadata and controls
165 lines (165 loc) · 4.04 KB
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
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
version: "2"
run:
tests: true
linters:
enable:
- asasalint
- asciicheck
- bidichk
- bodyclose
- contextcheck
- err113
- errchkjson
- errorlint
- exhaustive
- gocheckcompilerdirectives
- gochecksumtype
- gocritic
- gocyclo
- goheader
- gosec
- gosmopolitan
- loggercheck
- makezero
- misspell
- nilerr
- nilnesserr
- noctx
- protogetter
- reassign
- recvcheck
- revive
- rowserrcheck
- spancheck
- sqlclosecheck
- testifylint
- unparam
- zerologlint
disable:
- durationcheck
- goconst
- musttag
settings:
goheader:
template-path: code-header-template.txt
nestif:
min-complexity: 6
exclusions:
generated: lax
presets:
- comments
- common-false-positives
- legacy
- std-error-handling
rules:
- linters:
- deadcode
- errorlint
- gocyclo
path: _test\.go
- linters:
- bodyclose
- deadcode
- gocyclo
- unparam
- varcheck
path: pkg/webtests/*
- linters:
- gocritic
path: pkg/webtests/*
text: unlambda
- linters:
- bodyclose
path: pkg/modules/background/unsplash/unsplash\.go
- linters:
- err113
- exhaustive
path: pkg/migration/*
- linters:
- exhaustive
path: pkg/models/task_collection_filter\.go
- linters:
- gosec
path: pkg/utils/random_string\.go
text: 'G404:' # We don't care about cryptographically secure randomness when we're using that utility function.
- linters:
- err113
path: pkg/modules/dump/*
- linters:
- err113
path: pkg/
text: 'do not define dynamic errors, use wrapped static errors instead:'
- linters:
- gocritic
text: 'commentFormatting: put a space between `//` and comment text'
- linters:
- gocyclo
path: pkg/modules/migration
- linters:
- goheader
- gosmopolitan
- misspell
path: pkg/routes/api/v1/docs.go
- linters:
- goheader
text: Missed string
- linters:
- errorlint
path: pkg/.*/error.go
- linters:
- nilerr
path: pkg/models/favorites\.go
- path: pkg/models/project\.go
text: string `parent_project_id` has 3 occurrences, make it a constant
- linters:
- musttag
path: pkg/models/events\.go
- path: pkg/models/task_collection.go
text: append result not assigned to the same slice
- linters:
- testifylint
path: pkg/modules/migration/ticktick/ticktick_test.go
- linters:
- revive
path: pkg/migration/*
text: parameter 'tx' seems to be unused, consider removing or renaming it as
- linters:
- govet
path: pkg/models/typesense.go
text: 'structtag: struct field Position repeats json tag "position" also at'
- linters:
- gosec
path: pkg/cmd/user.go
text: 'G115: integer overflow conversion uintptr -> int'
- linters:
- gosec
text: 'G115: integer overflow conversion int64 -> uint64'
- linters:
- gosec
text: 'G115: integer overflow conversion int -> uint64'
- linters:
- recvcheck
text: the methods of "Permission" use pointer receiver and non-pointer receiver.
- linters:
- recvcheck
text: the methods of "SubscriptionEntityType" use pointer receiver and non-pointer receiver.
- linters:
- revive
path: pkg/utils/*
text: 'var-naming: avoid meaningless package names'
paths:
- third_party$
- builtin$
- examples$
- pkg/routes/api/v1/docs.go
- plugins-dev/..*
formatters:
enable:
- gofmt
- goimports
exclusions:
generated: lax
paths:
- third_party$
- builtin$
- examples$