Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function gitsq (){
- CURRENT_BRANCH=`git branch | /bin/grep ^* | cut -d" " -f2`
- UPSTREAM_BRANCH=$1
- POSTFIX="-final"
- echo "Squashing $CURRENT_BRANCH onto $CURRENT_BRANCH$POSTFIX \n"
- git checkout $UPSTREAM_BRANCH
- git checkout -b $CURRENT_BRANCH$POSTFIX
- git merge --squash --no-commit $CURRENT_BRANCH
- echo "DONE! Dont forget to commit\n"
- }
Add Comment
Please, Sign In to add comment