pre-commit
#!/usr/bin/env bash | |
current_date=`date +%Y_%m_%d_%H_%M`; | |
cd /Users/richardzilahi/zilahir/tuts/wp/1/wordpress/!sqldump | |
mkdir -p "$current_date"; | |
mysqldump --net_buffer_length="83000" -u wp_user -pwp_password -h 0.0.0.0 -P 32770 --skip-extended-insert wordpress > /Users/richardzilahi/zilahir/tuts/wp/1/wordpress/!sqldump/"$current_date"/"$current_date".sql | |
cd /Users/richardzilahi/zilahir/tuts/wp/1/wordpress/!sqldump/"$current_date"; | |
echo "adding new sql file to repo" | |
cd /Users/richardzilahi/zilahir/tuts/wp/1/wordpress/ | |
git add /Users/richardzilahi/zilahir/tuts/wp/1/wordpress/!sqldump/"$current_date"/"$current_date".sql |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This comment has been minimized.
Maybe change:
/Users/richardzilahi/
to~/
;)