Created
July 30, 2015 03:33
-
-
Save SauloSilva/4b13902db1135849a8c9 to your computer and use it in GitHub Desktop.
Git clean up
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
#!/bin/bash | |
MAIN_BRANCH=${1-master} | |
echo -e "$(tput setaf 2)** Executing Status command$(tput sgr0)" | |
git branch --merged | grep -v "\*" | grep -v $MAIN_BRANCH | grep -v dev | xargs -n 1 git branch -d |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment