Files
cozystack/scripts/common-envs.mk
Andrei Kvapil 3d962685ce Move project from aenix-io to cozystack repository
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2025-03-10 21:16:58 +01:00

17 lines
578 B
Makefile

REGISTRY := ghcr.io/cozystack/cozystack
PUSH := 1
LOAD := 0
VERSION = $(patsubst v%,%,$(shell git describe --tags --abbrev=0))
TAG = $(shell git describe --tags --exact-match 2>/dev/null || echo latest)
# Returns 'latest' if the git tag is not assigned, otherwise returns the provided value
define settag
$(if $(filter $(TAG),latest),latest,$(1))
endef
ifeq ($(VERSION),)
$(shell git remote add upstream https://github.com/cozystack/cozystack.git || true)
$(shell git fetch upstream --tags)
VERSION = $(patsubst v%,%,$(shell git describe --tags --abbrev=0))
endif