Skip to content

Instantly share code, notes, and snippets.

@Efrat19
Last active January 29, 2020 10:15
Show Gist options
  • Save Efrat19/a1f32f8f5308d60e520dc8626882177f to your computer and use it in GitHub Desktop.
Save Efrat19/a1f32f8f5308d60e520dc8626882177f to your computer and use it in GitHub Desktop.
delete git branches
git branch -r > branch.txt
# delete master branch and "/origin" from branch.txt, and then:
for i in $(cat branch.txt); do sleep 1 && git push origin --delete $i & done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment