ARO-RP/Makefile

25 строки
813 B
Makefile
Исходник Обычный вид История

2019-11-18 09:24:26 +03:00
rp:
go build -ldflags "-X main.gitCommit=$(shell git rev-parse --short HEAD)$(shell [[ $$(git status --porcelain) = "" ]] || echo -dirty)" ./cmd/rp
clean:
rm -f rp
image:
go get github.com/openshift/imagebuilder/cmd/imagebuilder
imagebuilder -f Dockerfile -t rp:latest .
test:
go generate ./...
go build ./...
gofmt -s -w cmd hack pkg
go run ./vendor/golang.org/x/tools/cmd/goimports -w -local=github.com/jim-minter/rp cmd hack pkg
go run ./hack/validate-imports/validate-imports.go cmd hack pkg
@[ -z "$$(ls pkg/util/*.go 2>/dev/null)" ] || (echo error: go files are not allowed in pkg/util, use a subpackage; exit 1)
@[ -z "$$(find -name "*:*")" ] || (echo error: filenames with colons are not allowed on Windows, please rename; exit 1)
go vet ./...
2019-11-21 05:32:34 +03:00
go test ./...
.PHONY: rp clean image test