-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.golangci.yml
More file actions
73 lines (66 loc) · 1.72 KB
/
Copy path.golangci.yml
File metadata and controls
73 lines (66 loc) · 1.72 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
# golangci-lint config for shellboto.
#
# Pragmatic subset: enables the linters that catch real bugs and passes
# on the current tree. Style-heavy linters (revive, gocritic) and
# exec-style false-positives (gosec G204) are disabled here — revisit
# during a dedicated style pass if desired.
version: "2"
run:
timeout: 3m
tests: true
linters:
default: none
enable:
- govet
- errcheck
- staticcheck
- ineffassign
- unused
- misspell
settings:
errcheck:
# Deferred Close / Remove on best-effort cleanup paths is a
# widespread idiom in this codebase; failing errcheck on them
# adds noise without catching bugs.
check-type-assertions: false
check-blank: false
exclude-functions:
- (*os.File).Close
- (*database/sql.DB).Close
- (io.Closer).Close
- (*gorm.io/gorm.DB).Close
- fmt.Fprintln
- fmt.Fprintf
- fmt.Fprint
- os.Remove
- os.RemoveAll
- os.Chmod
- os.MkdirAll
- (*github.com/go-telegram/bot.Bot).SendMessage
staticcheck:
checks:
- all
# QF* = "quickfix" suggestions (informational).
- -QF1002
- -QF1008
# ST1000 (package comment) / ST1003 (naming) / ST1020 (exported
# comment form) are style prescriptions; too much noise on the
# existing tree to fix incrementally. Revisit in a dedicated
# style pass.
- -ST1000
- -ST1003
- -ST1020
exclusions:
rules:
- path: _test\.go
linters:
- errcheck
- unused
formatters:
enable:
- gofmt
- goimports
settings:
goimports:
local-prefixes:
- github.com/amiwrpremium/shellboto