Update Makefile
This commit is contained in:
parent
7093a634aa
commit
820cc4d729
18
Makefile
18
Makefile
@ -1 +1,19 @@
|
|||||||
# note: call scripts from /scripts
|
# note: call scripts from /scripts
|
||||||
|
GOCMD=GO111MODULE=on go
|
||||||
|
|
||||||
|
linters-install:
|
||||||
|
@golangci-lint --version >/dev/null 2>&1 || { \
|
||||||
|
echo "installing linting tools..."; \
|
||||||
|
curl -sfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh| sh -s v1.21.0; \
|
||||||
|
}
|
||||||
|
|
||||||
|
lint: linters-install
|
||||||
|
$(PWD)/bin/golangci-lint run
|
||||||
|
|
||||||
|
test:
|
||||||
|
$(GOCMD) test -cover -race ./...
|
||||||
|
|
||||||
|
bench:
|
||||||
|
$(GOCMD) test -bench=. -benchmem ./...
|
||||||
|
|
||||||
|
.PHONY: test lint linters-install
|
||||||
|
Loading…
Reference in New Issue
Block a user