diff --git a/Makefile b/Makefile index b3a37c85c4..a8ac961f02 100644 --- a/Makefile +++ b/Makefile @@ -6,10 +6,10 @@ define PIP_COMPILE pip-compile $(1) --upgrade --verbose --resolver=backtracking --annotation-style=line endef -GIT_VERSION := $(shell git describe --always --tags) +GIT_VERSION := $(shell git describe --tags --long --match "v*" --first-parent) GIT_HASH := $(shell git rev-parse --short HEAD) TIMESTAMP := $(shell date '+%Y-%m-%d') -PACKAGE ?=github.com/flyteorg/flytestdlib +PACKAGE ?=github.com/flyteorg/flyte/flytestdlib LD_FLAGS="-s -w -X $(PACKAGE)/version.Version=$(GIT_VERSION) -X $(PACKAGE)/version.Build=$(GIT_HASH) -X $(PACKAGE)/version.BuildTime=$(TIMESTAMP)" TMP_BUILD_DIR := .tmp_build diff --git a/flyteadmin/Makefile b/flyteadmin/Makefile index 4a715a02ce..9372c0bfb8 100644 --- a/flyteadmin/Makefile +++ b/flyteadmin/Makefile @@ -5,11 +5,11 @@ include ../boilerplate/flyte/docker_build/Makefile include ../boilerplate/flyte/golang_test_targets/Makefile include ../boilerplate/flyte/end2end/Makefile -GIT_VERSION := $(shell git describe --always --tags) +GIT_VERSION := $(shell git describe --tags --long --match "v*" --first-parent) GIT_HASH := $(shell git rev-parse --short HEAD) TIMESTAMP := $(shell date '+%Y-%m-%d') # TODO(monorepo): Do we need to change this? This is used in the service that provides a version. -PACKAGE ?=github.com/flyteorg/flytestdlib +PACKAGE ?=github.com/flyteorg/flyte/flytestdlib LD_FLAGS="-s -w -X $(PACKAGE)/version.Version=$(GIT_VERSION) -X $(PACKAGE)/version.Build=$(GIT_HASH) -X $(PACKAGE)/version.BuildTime=$(TIMESTAMP)"