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

Re: Fwd: Should "head" also work for "HEAD" on case-insensitive FS?

From
Junio C Hamano <gitster@pobox.com>
Date
Jul 27, 2017, 15:26 UTC
Message-ID
<xmqqlgn9oq8q.fsf@gitster.mtv.corp.google.com>
In-Reply-To
<20170727143507.bezad7dnthx4nqtc@sigill.intra.peff.net>
Jeff King <peff@peff.net> writes:
Show 13 quoted lines
> On Wed, Jul 26, 2017 at 05:49:47PM -0700, Junio C Hamano wrote:
>
>> What I saw was that a test have ended up with .git/%46%4F%4F when it
>> was told to create a ref "FOO" (which indicates that "FOO" was
>> passed to the files backend), which later failed to read it back
>> because the pseudo_ref handling refs.c wanted to see ".git/FOO" on
>> the reading side.
>> 
>> Perhaps it is only a bug in t/t1405-main-ref-store.sh?
>
> An interesting related issue for pseudo-refs: if you encode HEAD as
> .git/%48%45%41%44, how will we recognize that directory as a git
> repository?

Yes, that is a valid point. I may have forgot to explain why the sample change in my message upthread special cases "HEAD" and leaves it untouched, but it is done for this exact reason.

Show 6 quoted lines
>   1. It should say "this is a git repo, but not a vintage I understand".
>      Not "this isn't a git repo, I'll keep looking".
>
>   2. How does a git version of the correct vintage decide "this is a git
>      repo, so I'll check its config for extensions.refBackend, and a-ha,
>      they _do_ have a HEAD". There's a chicken-and-egg problem.
Yes, exactly.
Previous: Jeff King
Message 11 of 11 in “Should "head" also work for "HEAD" on case-insensitive FS?”
  1. Ævar Arnfjörð BjarmasonJul 3, 2017
  2. Konstantin KhomoutovJul 4, 2017
  3. Ævar Arnfjörð BjarmasonJul 4, 2017
  4. Jeff KingJul 5, 2017
  5. Junio C HamanoJul 5, 2017
  6. Junio C HamanoJul 6, 2017
  7. Kenneth HsuJul 6, 2017
  8. Fwd: Should "head" also work for "HEAD" on case-insensitive FS?Michael Haggerty, Jul 27, 2017
  9. Fwd: Should "head" also work for "HEAD" on case-insensitive FS?Junio C Hamano, Jul 27, 2017
  10. Jeff KingJul 27, 2017
  11. Junio C HamanoJul 27, 2017

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.