Git pull --all branches - 让现有的Git分支跟踪远程分支?

Git pull all remote branches / git / branch / git-branch

我知道如何创建一个跟踪远程分支的新分支,但是如何使一个现有分支跟踪一个远程分支?

Pat Notz



Answer #1
grb explain create my_branch github
# git_remote_branch version 0.3.0

# List of operations to do to create a new remote branch and track it locally:
git push github master:refs/heads/my_branch
git fetch github
git branch --track my_branch github/my_branch
git checkout my_branch