So here\'s the situation:
$ git status
# On branch master
# Your branch is ahead of \'origin/master\' by [x] commits.
#
Note: this question was recently linked-to from Git: unable to get remote and local/server the same. Note that the date on the original question is September 2011; the then-most-current version of Git was 1.7.10. Git is now at version 2.26.2.
In versions of Git predating Git 1.8.4, running git pull origin master
suppresses updating the local name origin/master
. (So does running git fetch origin master
.)
Running git fetch
, with no additional arguments, causes all versions of Git—before and after 1.8.4—to update all remote-tracking names, including origin/master
. So that's the real explanation behind this mystery.