Last active
December 14, 2015 09:18
-
-
Save michaellopez/5063584 to your computer and use it in GitHub Desktop.
Squash Github pull request to 1 commit
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
| // Revised from http://blog.steveklabnik.com/posts/2012-11-08-how-to-squash-commits-in-a-github-pull-request | |
| git fetch upstream | |
| git checkout <branch name> | |
| git rebase upstream/master -i | |
| # choose squash for all of your commits, except the first one | |
| # Edit the commit message to make sense, and describe all your changes | |
| git push origin <branch name> -f |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment