diff --git a/Makefile b/Makefile index 2bdee355..27247fe6 100644 --- a/Makefile +++ b/Makefile @@ -67,10 +67,11 @@ endif # Version properties COMMIT=$(shell git rev-parse --short HEAD) +TAG_NAME=$(shell git describe --abbrev=0) +PRERELEASE_VERSION=$(shell git describe --abbrev=0) # TODO(a.garipov): The cut call is a temporary solution to trim # prerelease versions. See the comment in .goreleaser.yml. -TAG_NAME=$(shell git describe --abbrev=0 | cut -c 1-8) -RELEASE_VERSION=$(TAG_NAME) +RELEASE_VERSION=$(shell git describe --abbrev=0 | cut -c 1-8) SNAPSHOT_VERSION=$(RELEASE_VERSION)-SNAPSHOT-$(COMMIT) # Set proper version @@ -78,6 +79,8 @@ VERSION= ifeq ($(TAG_NAME),$(shell git describe --abbrev=4)) ifeq ($(CHANNEL),edge) VERSION=$(SNAPSHOT_VERSION) + else ifeq ($(CHANNEL),beta) + VERSION=$(PRERELEASE_VERSION) else VERSION=$(RELEASE_VERSION) endif