Strip version number suffixes

Suffixes such as -rc1 etc are not allowed by rpm tools.
This commit is contained in:
Jon Griffiths 2016-03-03 00:06:55 +13:00
parent dd03698218
commit 094b6613d1

View file

@ -6,7 +6,8 @@
# current working directory.
name=$1
version=$2
# Strip any trailing prefix from the version like -rc1 etc
version=$(echo "$2" | sed 's/\-.*//g')
if [[ ! -f platform/rpm/${name}.spec ]]; then
echo error: spec file not found for name \"${name}\"