diff --git a/restore.sh b/restore.sh index 3ca9e92..575624e 100755 --- a/restore.sh +++ b/restore.sh @@ -13,7 +13,7 @@ SQL=$(gunzip -c "$1") DB_NAME=${MYSQL_DATABASE:-${MYSQL_DB}} if [ -z "${DB_NAME}"] then - DB_NAME=$(echo "$SQL" | grep -oE '(Database: (\w*))' | cut -d ' ' -f 2) + DB_NAME=$(echo "$SQL" | grep -oE '(Database: (.+))' | cut -d ' ' -f 2) fi [ -z "${DB_NAME}" ] && { echo "=> database name cannot be found" && exit 1; }