Zálohování MySQL pomocí Subversion
#!/bin/bash
USER=root
PASS=password
DATABASE=schema
for I in $(mysql -N -B -u ${USER} --password=${PASS} -e "show tables from ${DATABASE}" -s --skip-column-names);.
do.
echo -ne "$I, "
mysqldump -u ${USER} --password=${PASS} ${DATABASE} $I --skip-dump-date --extended-insert=FALSE> "$I.sql";.
done
svn commit -m "" .
svn cleanup