GIT-VERSION-GEN: Use git project-version.
PATCH 1/1 GIT-VERSION-GEN: Use git project-version.
---
Hi *,
There are two little behaviour changes:
1.- the -dirty suffix is converted to .dirty
2.- the version from the file version does not get the -dirty suffix.
GIT-VERSION-GEN | 12 ++---------- 1 files changed, 2 insertions(+), 10 deletions(-)
GIT-VERSION-GEN +2 -10
@@ -3,9 +3,9 @@ #!/bin/sh GVF=GIT-VERSION-FILE DEF_VER=v1.4.2.GIT -# First try git-describe, then see if there is a version file +# First try git-project-version, then see if there is a version file # (included in release tarballs), then default -if VN=$(git describe --abbrev=4 HEAD 2>/dev/null); then +if VN=$(git project-version); then VN=$(echo "$VN" | sed -e 's/-/./g'); elif test -f version then
@@ -16,14 +16,6 @@ fi VN=$(expr "$VN" : v*'\(.*\)') -dirty=$(sh -c 'git diff-index --name-only HEAD' 2>/dev/null) || dirty= -case "$dirty" in -'') - ;; -*) - VN="$VN-dirty" ;; -esac - if test -r $GVF then VC=$(sed -e 's/^GIT_VERSION = //' <$GVF)
Signature · 1 line
1.4.2.rc3.g3f0a-dirty