Created
June 16, 2014 14:29
-
-
Save davglass/838ae7bb5e1d48bc4e8f to your computer and use it in GitHub Desktop.
Place this file in your path and you get: git squash {2..n}
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
#!/bin/bash | |
level=$1 | |
if [ "${level}" == "" ]; then | |
level=2 | |
fi | |
git rebase --interactive HEAD~${level} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment