Git更新所有分支.md
2019-11-06 本文已影响0人
AnthZh
//远程分支覆盖本地所有分支
git pull --all
for branch in `git branch -a | grep remotes | grep -v HEAD`; do git checkout -f -t -B ${branch##remotes/origin/} $branch; done;
git checkout master
//远程分支覆盖本地所有分支
git pull --all
for branch in `git branch -a | grep remotes | grep -v HEAD`; do git checkout -f -t -B ${branch##remotes/origin/} $branch; done;
git checkout master