does linting on docker build/ci now
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
2020-09-21 14:11:18 -07:00
parent 80951c130a
commit 699dc378a9
6 changed files with 523 additions and 21 deletions

View File

@@ -22,14 +22,22 @@ ifneq ($(UNAME_S),Darwin)
GOFLAGS = -ldflags "-linkmode external -extldflags -static $(GOLDFLAGS)"
endif
default: fmt
default: debug
commit: fmt lint
git commit -a
fmt:
go fmt ./...
#go fmt ./...
goimports -l -w .
golangci-lint run --fix
lint:
golangci-lint run
sh -c 'test -z "$$(gofmt -l .)"'
debug: build
GOTRACEBACK=all DEBUG=1 ./$(FN) 2>&1 | tee -a debug.log
GOTRACEBACK=all HISTORYPOSTER_DEBUG=1 ./$(FN) 2>&1 | tee -a debug.log
run: build
./$(FN)
@@ -48,9 +56,4 @@ go-get:
./$(FN): */*.go cmd/*/*.go go-get
cd cmd/$(FN) && go build -o ../../$(FN) $(GOFLAGS) .
vet:
go lint ./...
go vet ./...
bash -c 'test -z "$$(gofmt -l .)"'
.PHONY: build fmt test is_uncommitted docker dist hub upload-docker-image clean run rundebug default build-docker-image-dist