make a local branch track a remote branch code example
Example 1: create local branch to track remote
git checkout --track origin/some_remote_branch
Example 2: git local branch track remote
git branch --set-upstream foo upstream/foo
git checkout --track origin/some_remote_branch
git branch --set-upstream foo upstream/foo