coredns/plugin
Yong Tang 102cfbd7fe Use gometalinter and enforcing go fmt/lint/vet (#1108)
* Use gometalinter and enforcing go fmt/lint/vet

Before this PR go fmt is enabled, go lint is suggest only.
From time to time we have to manually check for go lint and go vet
for any issues.

This fix uses gometalinter and enforcing go fmt/lint/vet.
Several reasons:
- gometalinter could handle multiple linters concurrently
- gometalinter supports suppression with `// nolint[: <linter>]`

Previously one reason we didn't enable go lint was due to the
```
warning: context.Context should be the first parameter of a function (golint)
```
this is now possible with gometalinter and `// nolint: golint` (See changes).

This fix also discovered several go vet issues and fixes it.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>

* Fix several issues reported by gometalinter (go vet)

This commit fixes several issues reported by gometalinter (go vet).

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>

* Increase deadline

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
2017-09-24 11:59:04 +01:00
..
auto plugin/{file,auto}: drop fsnotify (#1090) 2017-09-20 17:28:23 +01:00
autopath pkg: add dnstest (#1098) 2017-09-21 15:15:47 +01:00
bind plugins: expand examples (#1077) 2017-09-15 09:56:05 +01:00
cache pkg: add dnstest (#1098) 2017-09-21 15:15:47 +01:00
chaos pkg: add dnstest (#1098) 2017-09-21 15:15:47 +01:00
debug plugins: expand examples (#1077) 2017-09-15 09:56:05 +01:00
dnssec pkg: add dnstest (#1098) 2017-09-21 15:15:47 +01:00
dnstap go lint/vet/misspell cleanup (#1105) 2017-09-22 16:13:04 -07:00
erratic pkg: add dnstest (#1098) 2017-09-21 15:15:47 +01:00
errors pkg: add dnstest (#1098) 2017-09-21 15:15:47 +01:00
etcd pkg: add dnstest (#1098) 2017-09-21 15:15:47 +01:00
federation pkg: add dnstest (#1098) 2017-09-21 15:15:47 +01:00
file go lint/vet/misspell cleanup (#1105) 2017-09-22 16:13:04 -07:00
health Fixing a small typo (#1097) 2017-09-21 07:22:13 +01:00
hosts pkg: add dnstest (#1098) 2017-09-21 15:15:47 +01:00
kubernetes Fix autopath crash when pods verified not enabled (#1099) 2017-09-21 18:06:35 +01:00
loadbalance pkg: add dnstest (#1098) 2017-09-21 15:15:47 +01:00
log pkg: add dnstest (#1098) 2017-09-21 15:15:47 +01:00
metrics pkg: add dnstest (#1098) 2017-09-21 15:15:47 +01:00
pkg go lint/vet/misspell cleanup (#1105) 2017-09-22 16:13:04 -07:00
pprof plugin: README.md updates (#1084) 2017-09-15 22:27:55 +01:00
proxy Make proxy examples better (#1080) 2017-09-15 11:30:10 +01:00
reverse pkg: add dnstest (#1098) 2017-09-21 15:15:47 +01:00
rewrite go lint/vet/misspell cleanup (#1105) 2017-09-22 16:13:04 -07:00
root plugins: expand examples (#1077) 2017-09-15 09:56:05 +01:00
secondary Remove the word middleware (#1067) 2017-09-14 09:36:06 +01:00
test golint cleanup (#1085) 2017-09-15 23:34:02 +01:00
tls Remove the word middleware (#1067) 2017-09-14 09:36:06 +01:00
trace plugin: README.md updates (#1084) 2017-09-15 22:27:55 +01:00
whoami pkg: add dnstest (#1098) 2017-09-21 15:15:47 +01:00
backend.go Remove the word middleware (#1067) 2017-09-14 09:36:06 +01:00
backend_lookup.go Remove the word middleware (#1067) 2017-09-14 09:36:06 +01:00
normalize.go Remove the word middleware (#1067) 2017-09-14 09:36:06 +01:00
normalize_test.go Remove the word middleware (#1067) 2017-09-14 09:36:06 +01:00
plugin.go Use gometalinter and enforcing go fmt/lint/vet (#1108) 2017-09-24 11:59:04 +01:00
plugin_test.go Remove the word middleware (#1067) 2017-09-14 09:36:06 +01:00