diff --git a/modules/git/Makefile b/modules/git/Makefile index e0421371..9a4fd02f 100644 --- a/modules/git/Makefile +++ b/modules/git/Makefile @@ -17,6 +17,7 @@ git/show: @echo "latest tag - $(GIT_LATEST_TAG)" @echo "tag - $(GIT_IS_TAG)" @echo "branch - $(GIT_IS_BRANCH)" + @echo "timestamp - $(GIT_TIMESTAMP)" ## Export git vars git/export: @@ -26,3 +27,4 @@ git/export: @echo "GIT_LATEST_TAG=$(GIT_LATEST_TAG)" @echo "GIT_IS_BRANCH=$(GIT_IS_BRANCH)" @echo "GIT_IS_TAG=$(GIT_IS_TAG)" + @echo "GIT_TIMESTAMP=$(GIT_TIMESTAMP)" diff --git a/modules/git/bootstrap.Makefile b/modules/git/bootstrap.Makefile index 76ca07de..51d7c8cc 100644 --- a/modules/git/bootstrap.Makefile +++ b/modules/git/bootstrap.Makefile @@ -5,6 +5,8 @@ export GIT_COMMIT_SHORT ?= $(shell $(GIT) rev-parse --verify --short HEAD) export GIT_BRANCH ?= $(shell $(GIT) rev-parse --abbrev-ref HEAD) export GIT_LATEST_TAG ?= $(shell $(GIT) describe --tags --abbrev=0 2>/dev/null) +export GIT_TIMESTAMP ?= $(shell $(GIT) log -1 --format=%ct 2>/dev/null) + ifeq ($(GIT_LATEST_TAG),) export GIT_LATEST_TAG="0.0.0" endif