Delete all git local branches
Posted: 3 Feb 2021, 2:59am - Wednesday

I was wondering how to delete all local git branch in Windows. But I didn't bother as I realized I got Cygwin anyway so I just took the Linux one... :) So I write a bash script named "" with this contents:

git checkout master
# git pull - optional
git status
git branch | grep -v "master" | xargs git branch -D