summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnjan Nath <kaludios@gmail.com>2022-05-21 12:59:51 +0530
committerAnjan Nath <kaludios@gmail.com>2022-05-21 13:03:37 +0530
commite307c8706fb9c6a81c00f31541420727cb5a40f2 (patch)
tree2528289293732a0771f887ae89180d094eb1bd07
parentfc15079e835dd02dbf3a838ab321f8d84411f37f (diff)
add 'lint' target to Makefile to quickly run the linter while developing
here we assume gosec is already available in the dev machine, gofmt and govet are part of the go-sdk
-rw-r--r--Makefile12
1 files changed, 12 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 3552bc0..71c6826 100644
--- a/Makefile
+++ b/Makefile
@@ -17,3 +17,15 @@ run-openvpn:
check:
curl https://wtfismyip.com/json
+
+.PHONY: lint
+lint: go-fmt go-vet go-sec
+
+go-fmt:
+ gofmt -s -l .
+
+go-vet:
+ go vet ./...
+
+go-sec:
+ gosec ./...