A fixed branch of a branch of a branch or a remote branch being tracked is just a branch with which you will interact by default when using the git pull and git push commands.
When you pull a branch into yours, you can do it explicitly:
git pull origin the_branch
It will select the remote origin , then origin/the_branch into your current branch.
If you always use the same branch for pulling, specifying the branch upstream, you can simply run git pull :
git branch --set-upstream-to origin/the_branch git pull
By default, when you start a new branch from a remote one, git will add it as a branch up:
git checkout -b origin/the_branch
When pressed, it is almost the same.
The push.default configuration will define the default branch to be clicked using git push without parameters.
With an upstream value, it will simply enter the upstream branch.
With a default value of simple it will do the same , but only if the branch names of the local and upstream are the same .
I will let you see the document to check other configuration options.
You can see the current branch branches of all branches with the -vv switch:
$ git branch -vv * my_branch 33f2d4c [origin/mybranch] a useful commit master 3ed8e99 [origin/master] Merge the_branch dbbb8c0 [origin/the_branch] commit on the branch
The inbound branch of the branch can also be transferred using the @{upstream} link:
$ git rev-parse --symbolic-full-name --abbrev-ref @{upstream} origin/the_branch
A push branch as equivalent to @{push} (it will be the same as @{upstream} in 99% of cases):
$ git rev-parse --symbolic-full-name --abbrev-ref @{push} origin/the_branch
The difference between @{upstream} and @{push} applies to cases where you use a triangular workflow: you extract read-only from the upstream project (usually this is a remote upstream call) and click on the recordable repository.
This refers to the forking workflow used on GitHub.
I made a (french) blog post about this, here is the auto-translate version .