1
1
mirror of https://pagure.io/fedora-kickstarts.git synced 2024-11-25 16:43:08 +00:00

Use git version to get version name

Using git version is simpler as it handles oddball cases internally.
Since we have been using mostly lightweight tags I have set it to
search those in addition to annotated tags for the best match. The
output for commits that don't have a tag seems a bit nicer as well.
This commit is contained in:
Bruno Wolff III 2013-10-18 15:10:14 -05:00
parent 9a57bcfb07
commit 1bdc87189a

View File

@ -1,9 +1,5 @@
# Get the version name first by seeing if HEAD is tagged
version := $(shell git tag --points-at HEAD -l '0.*.*' | sort -r | head -1)
# And if it wasn't use a git hash
ifeq ($(version),)
version := $(shell git log -1 --abbrev=8 --pretty=git%h)
endif
# Get a version name based off the nearest tag (include lightweight tags)
version := $(shell git describe --tags)
DESTDIR := /usr