Created
January 28, 2013 01:52
-
-
Save branquito/4652199 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
echo 'Importing *.sql into database..' | |
mysql -u user -ppassword dbname < /path/to/site/dbname-git.sql | |
echo '..done!' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
echo 'Dumping of database started..' | |
mysqldump -u user -ppassword --skip-extended-insert dbname > /path/to/site/dbname-git.sql | |
echo '..changing into server folder.' | |
cd /path/to/site/ | |
echo 'git adding *.sql file..' | |
git add dbname-git.sql | |
echo '..done!' | |
exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment