mirror of
https://git.notmuchmail.org/git/notmuch
synced 2024-12-23 01:44:52 +01:00
building from git: use --abbrev=7 for version string
Users may have set core.abbrev=n, where n != 7 in their git config file(s) which would give them different than expected version strings when building notmuch from git. This fixes the commit hash part of version string to 7 hexadecimal values.
This commit is contained in:
parent
40dc79d6ac
commit
bc64cdce28
1 changed files with 1 additions and 1 deletions
|
@ -21,7 +21,7 @@ endif
|
|||
VERSION:=$(shell cat ${srcdir}/version)
|
||||
ifeq ($(filter release release-message pre-release update-versions,$(MAKECMDGOALS)),)
|
||||
ifeq ($(IS_GIT),yes)
|
||||
VERSION:=$(shell git describe --match '[0-9.]*'|sed -e s/_/~/ -e s/-/+/ -e s/-/~/)
|
||||
VERSION:=$(shell git describe --abbrev=7 --match '[0-9.]*'|sed -e s/_/~/ -e s/-/+/ -e s/-/~/)
|
||||
# Write the file 'version.stamp' in case its contents differ from $(VERSION)
|
||||
FILE_VERSION:=$(shell test -f version.stamp && read vs < version.stamp || vs=; echo $$vs)
|
||||
ifneq ($(FILE_VERSION),$(VERSION))
|
||||
|
|
Loading…
Reference in a new issue