1
0
mirror of https://github.com/zokradonh/kopano-docker synced 2025-06-07 07:56:12 +00:00

Make build fail early if bad version string is received (#365)

* add basic version number check
This commit is contained in:
Felix Bartels 2020-03-15 19:24:37 +01:00 committed by GitHub
parent ae71b326a7
commit 646f5151f5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -80,4 +80,11 @@ filename=$(h5ai_query "$component" "$distribution" "$channel" "$branch")
currentVersion=$(version_from_filename "$filename")
versiontemp="${currentVersion//[^.]}"
# a valid version number has at least two dots. e.g. 1.2.3
if [ ${#versiontemp} -lt 2 ]; then
echo "Malformed version received"
exit 1
fi
echo "$currentVersion"