From 3a1fe3028453d2b582acf8bc65d859ef48f17cdc Mon Sep 17 00:00:00 2001 From: Peter Bourgon Date: Tue, 7 Jun 2016 20:02:50 +0200 Subject: [PATCH] lint: place here in preparation Eventually I would like to get this repo linting cleanly. For now I will just place the script here. --- lint | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100755 lint diff --git a/lint b/lint new file mode 100755 index 0000000..12e3072 --- /dev/null +++ b/lint @@ -0,0 +1,26 @@ +#!/usr/bin/env bash + +set -o errexit +set -o nounset +set -o pipefail + +if [ ! $(command -v gometalinter) ] +then + go get github.com/alecthomas/gometalinter + gometalinter --update --install +fi + +time gometalinter \ + --exclude='error return value not checked.*(Close|Log|Print).*\(errcheck\)$' \ + --exclude='.*_test\.go:.*error return value not checked.*\(errcheck\)$' \ + --exclude='/thrift/' \ + --exclude='/pb/' \ + --exclude='no args in Log call \(vet\)' \ + --disable=dupl \ + --disable=aligncheck \ + --disable=gotype \ + --cyclo-over=20 \ + --tests \ + --concurrency=2 \ + --deadline=300s \ + ./...