Created
March 10, 2017 17:11
-
-
Save peterchaula/2e18acb8a5d843aa6904febeff4e0d20 to your computer and use it in GitHub Desktop.
Commit and push in the case of a fire
This file contains 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
DATE="`date +%Y-%m-%d_%H_%M`"; \ | |
git add .; \ | |
git commit -m "Save ${DATE}"; \ | |
git push origin HEAD:backup-${DATE} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
wget -O /usr/loca/bin/git-backup https://gist.githubusercontent.com/peterchaula/2e18acb8a5d843aa6904febeff4e0d20/raw/1fde8d028b74aefeeb9ea36458fdfdc09ad05585/commit-and-push.sh
chmod +x /usr/local/bin/git-backup