git/list[1] front-page[2] threads[3] people[4] search[5] about
 

strange behaviour, default branch on clone not as expected

From
CFChris Friesen <chris.friesen@genband.com>
Date
Oct 3, 2011, 16:50 UTC
Message-ID
<4E89E7E1.4000907@genband.com>
Hi,

I have a bare repository on a server with (among others) branches "atca6900-ecgl" and "ncgl". The "HEAD" file in the bare repository contains "ref: refs/heads/ncgl" and "git branch" in the bare repository shows an asterisk beside "ncgl".

However, if I clone the bare repository I get "atca-6900-ecgl" as the default branch. ".git/HEAD" contains "ref: refs/heads/atca6900-ecgl".

Something that might be relevent--currently both of these branches 
actually point to the same commit (Don't ask, it's a vendor thing.) thus 
"refs/heads/atca6900-ecgl" and "refs/heads/ncgl" have the same contents. 
  I find it suspicious that atca6900-ecgl is alphabetically before ncgl 
and that they point to the same commit ID...but I don't know how it 
works internally so this may be just coincidence.

Any ideas what's going on? I'm using git 1.7.3.2 if it makes any difference.

Chris
-- 
Chris Friesen
Software Developer
GENBAND
chris.friesen@genband.com
www.genband.com
Next: Junio C Hamano
Message 1 of 2 in “strange behaviour, default branch on clone not as expected”
  1. Chris FriesenOct 3, 2011
  2. Junio C HamanoOct 3, 2011

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.