Skip to content

Instantly share code, notes, and snippets.

@grimzy
Created September 15, 2017 02:15
Embed
What would you like to do?
Git pull all remote branches
#!/usr/bin/env bash
git branch -r | grep -v '\->' | while read remote; do git branch --track "${remote#origin/}" "$remote"; done
git fetch --all
git pull --all
@m3asmi
Copy link

m3asmi commented Jul 13, 2022

@jcwren thanks, I fixed it

@CynCity17
Copy link

This was so helpful! Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment