Import .sql files from current directory to MySQL Posted on March 4, 2018June 21, 2019 by admin M_P=$(cat /etc/psa/.psa.shadow); for db in *.sql; do echo "Restoring ${db::-4}"; MYSQL_PWD=$M_P mysql -uadmin < "$db"; done