github.com/enbility/spine-go@v0.7.0/.golangci.yml (about) 1 run: 2 # timeout for analysis, e.g. 30s, 5m, default is 1m 3 timeout: 5m 4 5 # include test files or not, default is true 6 tests: true 7 8 # by default isn't set. If set we pass it to "go list -mod={option}". From "go help modules": 9 # If invoked with -mod=readonly, the go command is disallowed from the implicit 10 # automatic updating of go.mod described above. Instead, it fails when any changes 11 # to go.mod are needed. This setting is most useful to check that go.mod does 12 # not need updates, such as in a continuous integration and testing system. 13 # If invoked with -mod=vendor, the go command assumes that the vendor 14 # directory holds the correct copies of dependencies and ignores 15 # the dependency descriptions in go.mod. 16 modules-download-mode: readonly 17 18 # output configuration options 19 output: 20 # colored-line-number|line-number|json|tab|checkstyle|code-climate, default is "colored-line-number" 21 formats: 22 - format: colored-line-number 23 24 linters: 25 enable: 26 - bodyclose 27 - errcheck 28 - errorlint 29 - gocheckcompilerdirectives 30 - gochecknoinits 31 - gochecksumtype 32 - goconst 33 - gofmt 34 - gosimple 35 - gosec 36 - govet 37 - nilerr 38 - nilnil 39 - staticcheck 40 - typecheck 41 - unused 42 - whitespace 43 44 issues: 45 # Excluding configuration per-path, per-linter, per-text and per-source 46 exclude-rules: 47 # Exclude some linters from running on tests files. 48 - path: _test\.go 49 linters: 50 - errcheck 51 - goconst 52 - gosec 53 54 # checking for errors in defers seldom makes sense... 55 - source: "^\\s*defer\\s" 56 linters: 57 - errcheck 58 - staticcheck