X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=GIT-VERSION-GEN;h=72201be57c633259e65b435f8623a80e4cdc3e88;hb=bd6a9e885aec97999041307b76d73de4605f25db;hp=73aaff0a2979de8bcfd72f8a10793a07f17c18ad;hpb=c4e804bbf0c16aa0c2234ea733fba73de28bddaa;p=git.git diff --git a/GIT-VERSION-GEN b/GIT-VERSION-GEN index 73aaff0a2..72201be57 100755 --- a/GIT-VERSION-GEN +++ b/GIT-VERSION-GEN @@ -5,9 +5,11 @@ DEF_VER=v1.1.GIT # First try git-describe, then see if there is a version file # (included in release tarballs), then default -VN=$(git-describe --abbrev=4 HEAD 2>/dev/null) || -VN=$(cat version) || -VN="$DEF_VER" +if VN=$(git-describe --abbrev=4 HEAD 2>/dev/null); then + VN=$(echo "$VN" | sed -e 's/-/./g'); +else + VN=$(cat version) || VN="$DEF_VER" +fi VN=$(expr "$VN" : v*'\(.*\)')