aks-engine-azurestack/Makefile

37 строки
1.0 KiB
Makefile
Исходник Обычный вид История

2016-10-24 20:32:22 +03:00
.NOTPARALLEL:
2017-03-09 02:04:50 +03:00
.PHONY: prereqs build test test_fmt validate-generated fmt lint ci devenv
2017-01-10 23:29:27 +03:00
2017-03-21 08:55:10 +03:00
VERSION=`git describe --always --long --dirty`
BUILD=`date +%FT%T%z`
2017-05-17 23:06:24 +03:00
# this isn't particularly pleasant, but it works with the least amount
# of requirements around $GOPATH. The extra sed is needed because `gofmt`
# operates on paths, go list returns package names, and `go fmt` always rewrites
# which is not what we need to do in the `test_fmt` target.
GOFILES=`go list ./... | grep -v "github.com/Azure/acs-engine/vendor" | sed 's|github.com/Azure/acs-engine|.|g' | grep -v -w '^.$$'`
all: build
2017-02-22 00:40:31 +03:00
prereqs:
2017-05-17 23:06:24 +03:00
go get github.com/Masterminds/glide
2017-02-09 22:18:57 +03:00
go get github.com/jteeuwen/go-bindata/...
2017-05-17 23:06:24 +03:00
glide install
build:
2017-05-17 23:06:24 +03:00
go generate -v $(GOFILES)
go build -v -ldflags="-X github.com/Azure/acs-engine/cmd.BuildSHA=${VERSION} -X github.com/Azure/acs-engine/cmd.BuildTime=${BUILD}"
cd test/acs-engine-test; go build -v
2016-10-24 20:32:22 +03:00
2017-05-30 03:26:06 +03:00
test: test_fmt
2017-05-17 23:06:24 +03:00
go test -v $(GOFILES)
2016-10-24 20:32:22 +03:00
2017-05-30 03:26:06 +03:00
.PHONY: test-style
test-style:
@scripts/validate-go.sh
2017-03-09 02:04:50 +03:00
ci: prereqs build test lint
2016-10-24 20:32:22 +03:00
devenv:
2017-05-16 00:10:29 +03:00
./scripts/devenv.sh