Re: GIT - error: no such remote ref refs/heads/TestBranch

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



"Sean Kelley" <sean.v.kelley@xxxxxxxxx> writes:

> Hi,
>
> I was wondering if someone could help me.  I had a branch on our
> remote GIT server called TestBranch.  I logged into the Remote server
> and ran:
>
> <from remote server>
> git branch -D TestBranch
>
> But in my local clone:
>
> kelleys@oifig:~/Work/kernel$ git pull origin
> kelleys@xxxxxxxxxxxxxxx's password:
> error: no such remote ref refs/heads/TestBranch
> Fetch failure: git+ssh://git.example.com/data/git/proj/kernel/mh.git
> kelleys@oifig:~/Work/kernel$
>
> Any ideas how to correct this?

If you know remote does not have it, then probably not fetching
from it would be a good idea.

Look at your local $GIT_DIR/remotes/origin (or [remote "origin"]
section in $GIT_DIR/config) and remove the refspec that tells
git to fetch it.

In $GIT_DIR/remotes/origin, you may want to remove a like like this:

	Pull: refs/heads/TestBranch:<something>

If it is coming from $GIT_DIR/config, it would probably look
like:

	[remote "origin"]
        	fetch = refs/heads/TestBranch:<something>

and you would want to remove the "fetch = " line.

-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]