From f06473fbb45df56e1228d9c179c07521c271d27e Mon Sep 17 00:00:00 2001 From: Markus Armbruster Date: Sat, 26 Dec 2020 08:34:33 +0100 Subject: [PATCH] build-aux/git-version-gen: Refresh from Gnulib commit 4f78c231f4 Signed-off-by: Markus Armbruster --- build-aux/git-version-gen | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/build-aux/git-version-gen b/build-aux/git-version-gen index e77d5e91d..f4e85924f 100755 --- a/build-aux/git-version-gen +++ b/build-aux/git-version-gen @@ -1,8 +1,8 @@ #!/bin/sh # Print a version string. -scriptversion=2017-08-07.06; # UTC +scriptversion=2019-10-13.15; # UTC -# Copyright (C) 2007-2018 Free Software Foundation, Inc. +# Copyright (C) 2007-2020 Free Software Foundation, Inc. # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -15,9 +15,9 @@ scriptversion=2017-08-07.06; # UTC # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with this program. If not, see . +# along with this program. If not, see . -# This script is derived from GIT-VERSION-GEN from GIT: http://git.or.cz/. +# This script is derived from GIT-VERSION-GEN from GIT: https://git-scm.com/. # It may be run two ways: # - from a git repository in which the "git describe" command below # produces useful output (thus requiring at least one signed tag) @@ -72,9 +72,10 @@ scriptversion=2017-08-07.06; # UTC me=$0 +year=`expr "$scriptversion" : '\([^-]*\)'` version="git-version-gen $scriptversion -Copyright 2011 Free Software Foundation, Inc. +Copyright $year Free Software Foundation, Inc. There is NO warranty. You may redistribute this software under the terms of the GNU General Public License. For more information about these matters, see the files named COPYING." @@ -141,11 +142,9 @@ then v=`cat $tarball_version_file` || v= case $v in *$nl*) v= ;; # reject multi-line output - [0-9]*) ;; - *) v= ;; esac test "x$v" = x \ - && echo "$0: WARNING: $tarball_version_file is missing or damaged" 1>&2 + && echo "$0: WARNING: $tarball_version_file is damaged" 1>&2 fi if test "x$v" != x @@ -167,7 +166,8 @@ then # tag or the previous older version that did not? # Newer: v6.10-77-g0f8faeb # Older: v6.10-g0f8faeb - case ${v#-g*} in + vprefix=`expr "X$v" : 'X\(.*\)-g[^-]*$'` || vprefix=$v + case $vprefix in *-*) : git describe is probably okay three part flavor ;; *) : git describe is older two part flavor @@ -218,7 +218,7 @@ fi printf %s "$v" # Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" -- 2.43.0