golangci-lint round #3

this is the third round of preparing to use the golangci-lint on our
code base.

Signed-off-by: baude <bbaude@redhat.com>
This commit is contained in:
baude
2019-07-11 05:44:12 -05:00
parent a5aa44c583
commit db826d5d75
51 changed files with 161 additions and 150 deletions

55
.golangci.yml Normal file
View File

@ -0,0 +1,55 @@
---
run:
build-tags:
- apparmor
- ostree
- seccomp
- selinux
concurrency: 6
deadline: 5m
skip-dirs:
- dependencies/*
- contrib
- test/e2e
- docs
- test/
- tracing
skip-files:
- iopodman.go
linters:
disable-all: true
enable:
- bodyclose
- deadcode
- depguard
# dupl really overdid it; disabling
# - dupl
- errcheck
- gofmt
- gosimple
- govet
- ineffassign
- nakedret
- staticcheck
- structcheck
- typecheck
- unused
- varcheck
# - gochecknoglobals
# - gochecknoinits
# - goconst
# - gocritic
# - gocyclo
# - goimports
# - golint
# - gosec
- interfacer
# - lll
# - maligned
# - misspell
# - prealloc
- scopelint
- stylecheck
- unconvert
# I think we should uncomment this one and used it
# - unparam