On Thu, 4 Oct 2012 15:14:27 +0400
Konstantin Khomoutov <flatw...@users.sourceforge.net> wrote:
> Second, what you're facing is probably because you have one remote
> branch, which is really "remotes/origin/branches" and one local
> branch, which is called "origin/master" -- you can see the difference
> by running `git branch -a`.
> To deal with this situation, refer to the remote branch via its
> "fuller" name, remotes/origin/master.
> Supposedly you should examine what's the difference between your local
> branch "master" and your (probably wrongly named) branch
> "origin/master" and decide which one to keep and which one to delete.
> Also note that you can rename any branch using `git branch -m`.
To further expand on this topic -- the way Git resolves branch names to
their real full names is explained in the section "SPECIFYING REVISIONS"
of the `git rev-parse` manual .
>From that, you can gather that when you tell Git your branch is named
"origin/master", it first tries to find a branch having the full
name "refs/heads/origin/master" (a local branch) and only if this fails,
it tries to find "refs/remotes/origin/master" (a remote branch), so
when you have a name clash like this, you should somehow disambiguate
the name so Git looks finds what was intended.
You received this message because you are subscribed to the Google Groups "Git
for human beings" group.
To post to this group, send email to email@example.com.
To unsubscribe from this group, send email to
For more options, visit this group at