Files
init-env/home/bin/git-cleanup
T
2018-03-23 16:11:19 -06:00

13 lines
202 B
Bash
Executable File

#!/usr/bin/env bash
git fetch -p
git checkout master
git pull
git branch --merged master | grep -v master | while read BRANCH; do
git branch -d $BRANCH
done
echo "Branches remaining:"
git branch