Make: remove 'v3.0-beta1-' prefix from "git hash"

`git describe --dirty --always` will produce a hash in the form
`{most recent tag}-{commits since that tag}-{hash}` with a `-dirty` suffix
when there are uncommitted changes. Since the app version and the most
recent tag already overlap, the app version is removed from the git hash
to avoid overly long hashes. They are now of the form `{commits since last
tag}-{hash}`.
This commit is contained in:
Sybren A. Stüvel 2022-08-04 17:04:55 +02:00
parent edb181d2eb
commit edf8309118

View File

@ -5,7 +5,7 @@ PKG := git.blender.org/flamenco
VERSION := 3.0-beta1 VERSION := 3.0-beta1
RELEASE_CYCLE := beta RELEASE_CYCLE := beta
GITHASH := $(shell git describe --dirty --always) GITHASH := $(subst v${VERSION}-,,$(shell git describe --dirty --always))
LDFLAGS := -X ${PKG}/internal/appinfo.ApplicationVersion=${VERSION} \ LDFLAGS := -X ${PKG}/internal/appinfo.ApplicationVersion=${VERSION} \
-X ${PKG}/internal/appinfo.ApplicationGitHash=${GITHASH} \ -X ${PKG}/internal/appinfo.ApplicationGitHash=${GITHASH} \
-X ${PKG}/internal/appinfo.ReleaseCycle=${RELEASE_CYCLE} -X ${PKG}/internal/appinfo.ReleaseCycle=${RELEASE_CYCLE}