Skip to content

Commit

Permalink
site: set fallback version (#80)
Browse files Browse the repository at this point in the history
Add a fallback version, which is applied in case the site is built
without tags fetched. This ensures the version string is not empty.

The fallback-version is set when branching a release off. It is et to
the minor-version only. The patch version is omitted, like it is
currently done for testing images.

Signed-off-by: David Bauer <[email protected]>
  • Loading branch information
blocktrron authored Jun 13, 2024
1 parent 3a97fcb commit 071eba4
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion site.mk
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
FFDA_SITE_DIR:=$(shell dirname $(realpath $(lastword $(MAKEFILE_LIST))))
FFDA_SITE_VERSION := $(shell git -C $(FFDA_SITE_DIR) describe --tags --abbrev=0 | sed 's/-.*//')
FFDA_SITE_VERSION_GIT := $(shell git -C $(FFDA_SITE_DIR) describe --tags --abbrev=0 | sed 's/-.*//')

FFDA_SITE_VERSION_FALLBACK := 3.1
FFDA_SITE_VERSION := $(if $(FFDA_SITE_VERSION_GIT),$(FFDA_SITE_VERSION_GIT),$(FFDA_SITE_VERSION_FALLBACK))

DEFAULT_GLUON_RELEASE := $(FFDA_SITE_VERSION)~$(shell date '+%Y%m%d')
DEFAULT_GLUON_PRIORITY := 0
Expand Down

0 comments on commit 071eba4

Please sign in to comment.