mirror of
https://github.com/pushbits/server.git
synced 2025-08-03 16:48:38 +02:00
24 lines
468 B
Makefile
24 lines
468 B
Makefile
IMAGE := eikendev/pushbits
|
|
|
|
.PHONY: test
|
|
test:
|
|
stdout=$$(gofmt -l . 2>&1); \
|
|
if [ "$$stdout" ]; then \
|
|
exit 1; \
|
|
fi
|
|
gocyclo -over 10 $(shell find . -iname '*.go' -type f)
|
|
go test -v -cover ./...
|
|
stdout=$$(golint ./... 2>&1); \
|
|
if [ "$$stdout" ]; then \
|
|
exit 1; \
|
|
fi
|
|
|
|
.PHONY: tools
|
|
tools:
|
|
go get -u github.com/fzipp/gocyclo
|
|
go get -u golang.org/x/lint/golint
|
|
|
|
.PHONY: push-image
|
|
push-image:
|
|
docker build -t ${IMAGE}:latest .
|
|
docker push ${IMAGE}:latest
|