Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Git fetch all remote branches to local machine
git branch -r | grep -v '\->' | while read remote; do git branch --track "${remote#origin/}" "$remote"; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment