Skip to content

Instantly share code, notes, and snippets.

@Mrkisha
Created June 22, 2016 11:25
Show Gist options
  • Save Mrkisha/a028b31b8be034549d85468bde2d0c4e to your computer and use it in GitHub Desktop.
Save Mrkisha/a028b31b8be034549d85468bde2d0c4e to your computer and use it in GitHub Desktop.
Bash command to dump database into file with content and append timestamp to file
mysqldump -u <user> --password=<password> <database> > ~/somefolder/some-file-name-$(date -d "today" +"%Y%m%d%H%M").sql
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment