install_mysql.sh: Fix error in determin 'CURRENT_VERSION' in case of MySQL 8.0.x

This commit is contained in:
Christoph 2019-11-01 03:14:57 +01:00
parent 09503b925e
commit efc8cb9fc2

View File

@ -314,7 +314,7 @@ if $UPDATE_MYSQL ; then
echo_ok
echononl "Get current MySQL Version.."
CURRENT_VERSION="$(echo $_MYSQLD_VERSION | grep -o -E "[0-9]+\.[0-9]+\.[0-9]+(-[0-9]+)?")"
CURRENT_VERSION="$(echo $_MYSQLD_VERSION | grep -o -E "[0-9]+\.[0-9]+\.[0-9]+(-[0-9]+)?" | head -n 1)"
CURRENT_MAIN_VERSION="$(echo $CURRENT_VERSION | cut -d '.' -f1,2)"
if [[ -n "$CURRENT_VERSION" ]]; then
echo_ok