Created
September 2, 2021 15:12
-
-
Save Lukas238/6c8e63ddb04b685946d47c3bb0638098 to your computer and use it in GitHub Desktop.
Script to make a DataBase dump to file, without comments.
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/bash | |
# This script will dump the DB to file. | |
# Replace DB_USER, DB_PASS, and DB_NAME with your data base user, password and name. | |
# Mind the lack of gap apfter the `-p` argument. :) | |
# To run it use `sh do_backup.sh` | |
mysqldump -u DB_USER -pDB_PASS DB_NAME --skip-comments --host localhost > db_backup/db_backup.sql |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment