sanitize version information output

This commit is contained in:
root@zero 2016-08-03 07:51:53 +02:00
parent 56c1ed5fe1
commit 82df0a4398
1 changed files with 3 additions and 2 deletions

5
vpm
View File

@ -18,7 +18,8 @@ colordarkgray=245
colorbrackets=242
getversion () {
cd "${0%/*}"
fp="$(readlink -f $0)"
cd "${fp%/*}"
git describe --all --debug --long --tags 2>/dev/null || echo "UNKNOWN"
}
@ -103,7 +104,7 @@ version () {
color sgr0
msg "vpm - Version: $version"
msg "Copyright (c) 2016 Armin Jenewein <a@m2m.pm> (GPLv3+)"
msg "XBPS version: $(xbps-query -v --version)"
msg "XBPS version: $(xbps-query -v --version | sed 's/GIT: UNSET//')"
}
# extract versionstring appendix from given package name