ci: fix tagging
ZeroDownTime/jenkins-hugo/pipeline/head This commit looks good Details
ZeroDownTime/jenkins-hugo/pipeline/tag Something is wrong with the build of this commit Details

This commit is contained in:
Stefan Reimer 2022-12-22 14:15:41 +00:00
parent ef1911406e
commit e7e9a0a647
1 changed files with 3 additions and 1 deletions

View File

@ -5,7 +5,9 @@ GIT_TAG := $(shell git describe --tags --match v*.*.* 2>/dev/null || git rev-par
# append branch name to tag if NOT main nor master
TAG := $(GIT_TAG)
ifeq (,$(filter main master, $(GIT_BRANCH)))
TAG = $(GIT_TAG)-$(GIT_BRANCH)
ifneq ($(GIT_TAG), $(GIT_BRANCH))
TAG = $(GIT_TAG)-$(GIT_BRANCH)
endif
endif
# optionally set by the caller