Fix version header

This commit is contained in:
Armin Jenewein 2020-04-17 22:07:12 +02:00
parent 758891d935
commit 7c979c7c12
1 changed files with 6 additions and 8 deletions

14
vpm
View File

@ -10,6 +10,12 @@
# Released under the terms of the GNU general public license, version 3+
# see LICENSE file for license information.
# set version number
version="1.3"
# disable verbosity, by default
verbose=false
# VPM color definitions
numcolorok=2
numcolorfail=1
@ -21,15 +27,7 @@ numcolorpkgcount=8
numcolordarkgray=11
numcolorbrackets=6
getversion () {
local fp=$(readlink -f "$0")
(cd "${fp%/*}" && \
git describe --all --debug --long --tags 2>/dev/null) || echo "UNKNOWN"
}
version=$(getversion)
progname=${0##*/}
verbose=false
# enable or disable colors based on the argument given, i.e.:
# setcolors on # colors on