DATE?=$(shell date -u "+%Y-%m-%d %H:%M:%S") LDFLAGS=-s -w -X 'main.AppVersion=${app_version}' -X 'main.BuildDate=${DATE}' LDFLAGS=-X 'main.AppVersion=${app_version}' -X 'main.BuildDate=${DATE}' GOPATH=$(shell go env GOPATH) .PHONY: build build: GOWORK=off CGO_ENABLED=0 go build -ldflags "$(LDFLAGS)" -gcflags=-trimpath=$(GOPATH) -asmflags=-trimpath=$(GOPATH) -trimpath -mod=readonly -o micro-gen go.unistack.org/micro-gen .PHONY: test test: go test -mod=readonly -race -v ./... -cover