From 4e156b8f26db33c3f8e72648f766251aa2d2f2b3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vin=C3=ADcius=20Garcia?= Date: Fri, 11 Sep 2020 18:48:48 -0300 Subject: [PATCH] Add Makefile --- .gitignore | 1 + Makefile | 18 ++++++++++++++++++ 2 files changed, 19 insertions(+) create mode 100644 .gitignore create mode 100644 Makefile diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..12e9678 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.make.setup diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..cba4e80 --- /dev/null +++ b/Makefile @@ -0,0 +1,18 @@ +args= +path=./... + +GOPATH=$(shell go env GOPATH) + +test: setup + $(GOPATH)/bin/richgo test $(path) $(args) + +lint: setup + @$(GOPATH)/bin/golint -set_exit_status -min_confidence 0.9 $(path) $(args) + @go vet $(path) $(args) + @echo "Golint & Go Vet found no problems on your code!" + +setup: .make.setup +.make.setup: + go get github.com/kyoh86/richgo + go get golang.org/x/lint + touch .make.setup