Watch out, as some of those have broken vendor support.
Here's notes we've made in the past (might be out of date)
* Disable gotype, errcheck, dupl and structcheck as they are awful.
* Disable interfacer and gas as they too picky.
* Disable gofmt as its redundant and also sometimes gets false
positives via metalinter.
* Disable unconvert, aligncheck and varcheck which aren't vendor
compatible.
On 15/11/2016 06:39, Dobrosław Żybort wrote:
Neat idea.
Just some random thought: instead of adding all linters by hand maybe
you could use what gometalinter already provide?
https://github.com/alecthomas/gometalinter
W dniu poniedziałek, 14 listopada 2016 14:27:26 UTC+1 użytkownik
sri...@laddoo.net napisał:
Hi,
I'd like to announce a library I just released called lint [1]. It
allows you to run a variety of linters as part of go test. It also
supports whitelisting false positives. It reduces the need for
build scripts, makes CI integration easy and lets projects enforce
linter usage without extra scripts. I built it while working on
our mobile app (which is written in Go) and have found it useful
so far.
The below example test will check for gofmt usage, run go tool vet
--shadow, golint, errcheck, gosimple and gostaticcheck
import (
"testing"
"github.com/surullabs/lint <http://github.com/surullabs/lint>"
)
func TestLint(t *testing.T) {
if err := lint.Default.Check("./..."); err != nil {
t.Fatal("lint failures: %v", err)
}
}
Please let me know if you find this useful and if you'd like any
features added/removed/modified.
Thanks!
Sridhar
[1] https://www.timeferret.com/lint <https://www.timeferret.com/lint>
--
You received this message because you are subscribed to the Google
Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to golang-nuts+unsubscr...@googlegroups.com
<mailto:golang-nuts+unsubscr...@googlegroups.com>.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to golang-nuts+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.