aboutsummaryrefslogtreecommitdiff
path: root/.ci
diff options
context:
space:
mode:
authoraaronbuchwald <[email protected]>2020-12-14 19:32:25 -0500
committerGitHub <[email protected]>2020-12-14 19:32:25 -0500
commit95cc7cb766d5bb23a771da35b3774159b2e1e1d1 (patch)
tree25b8a74353b87544f62f25f23ce0f721861a80f1 /.ci
parentac8d216710a533e1dae2f1215ff41e7f0fc2effe (diff)
parentde9c3bc629f7e712b3cd84b280db6a32b9bc7030 (diff)
Merge pull request #70 from ava-labs/fix-linting
Fix linting and add to CI
Diffstat (limited to '.ci')
-rwxr-xr-x.ci/lint.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/.ci/lint.sh b/.ci/lint.sh
new file mode 100755
index 0000000..cde7292
--- /dev/null
+++ b/.ci/lint.sh
@@ -0,0 +1,12 @@
+# binary will be $(go env GOPATH)/bin/golangci-lint
+curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.30.0
+# or install it into ./bin/
+curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s v1.30.0
+# In alpine linux (as it does not come with curl by default)
+wget -O- -nv https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s v1.30.0
+
+export PATH=$PATH:$(go env GOPATH)/bin
+
+golangci-lint --version
+
+golangci-lint run --max-same-issues 0 \ No newline at end of file