Merge pull request #527 from johanfagerstroem/master

Changing name validation regex to allow dashes
This commit is contained in:
redfast00 2018-05-09 01:47:29 +02:00 committed by GitHub
commit 548492832d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -141,8 +141,8 @@ if [ -z "${NAME}" ]; then
read -r NAME
fi
if [[ "${NAME}" =~ [^a-zA-Z0-9] ]]; then
echo "Name can only contain alphanumeric characters."
if [[ "${NAME}" =~ [^a-zA-Z0-9\-] ]]; then
echo "Name can only contain alphanumeric characters and dashes (-)."
exit 1
fi