Thread (7 messages) flat view 7 messages, 4 authors, 2016-06-15

Re: Odd problem in repository

From: Shawn O. Pearce <hidden>
Date: 2016-06-15 22:43:06

Clark Williams [off-list ref] wrote:
One of my collaborators cloned the repository the other day and found
that it didn't have any branches in it. I cloned a temp copy of it and
found that the files that normally would be in refs/heads to identify
the branches had somehow been moved to the directory
refs/remotes/origin. In my local repository (which was cloned
immediately after the CVS import), if I list what's in refs/heads, I get
this:

$ ls -F refs/heads
master  mock  mock-0-6-branch  mock-0.7  origin

on the whacky cloned copy, I get this:
$ ls -F refs/heads
master

and if I look in refs/remotes/origin:
$ ls -F refs/remotes/origin
HEAD  master  mock  mock-0-6-branch  mock-0.7  origin
This is a change in Git versions.  Pre Git-1.5.0 we used to put all
of the branches from the remote system into refs/heads, but now in
1.5.0 and later we put them in refs/remotes/origin.

Nothing screwed up on the central repository, its just the
new layout.  refs/heads is reserved for *this* local repository,
while refs/remotes/$name is reserved for the heads of $name remote
repository.

-- 
Shawn.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help