Go v1.11 (#60)

* Go v1.11
* [Go Modules](https://github.com/golang/go/wiki/Modules)
* [GolangCI-Lint](https://github.com/golangci/golangci-lint)
* [Distroless](https://github.com/GoogleContainerTools/distroless) docker image
This commit is contained in:
Adrian Macneil 2018-12-01 22:28:47 -08:00 committed by GitHub
parent abc544b368
commit da3d9525cf
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 47 additions and 117 deletions

View file

@ -1,30 +1,21 @@
DC := docker-compose
BUILD_FLAGS := -ldflags '-s'
PACKAGES := . ./pkg/...
.PHONY: all
all: dep install test lint build
.PHONY: dep
dep:
dep ensure -vendor-only
.PHONY: install
install:
go install -v $(PACKAGES)
all: test lint build
.PHONY: test
test:
go test -v $(PACKAGES)
go test -v ./...
.PHONY: lint
lint:
gometalinter.v2 $(PACKAGES)
golangci-lint run
.PHONY: wait
wait:
dbmate -e MYSQL_URL wait
dbmate -e POSTGRESQL_URL wait
dist/dbmate-linux-amd64 -e MYSQL_URL wait
dist/dbmate-linux-amd64 -e POSTGRESQL_URL wait
.PHONY: clean
clean: