Last Updated: February 25, 2016·
Roll Back Git Repo
We like to use Heroku as a staging environment in my office. However, Heroku only accepts pushes from the Master branch, so when we moved off Heroku our commit history was a mess.
After branching off and pushing a new branch off Master, this nice little command helped me roll back the master branch to a more stable point, and sync it up with our production environment
git push -f <remote> <commit-hash>:<branch>
Written by Aaron Miler
A better git log
Please, oh please, use git pull --rebase
git commit --allow-empty
Have a fresh tip? Share with Coderwall community!
Post a tip
Best #Git Authors
Sponsored by #native_company# — Learn More