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

Re: [git-for-windows] Case insensitive branch names

From
Junio C Hamano <gitster@pobox.com>
Date
Dec 21, 2015, 17:37 UTC
Message-ID
<xmqqa8p3hfej.fsf@gitster.mtv.corp.google.com>
In-Reply-To
<CACsJy8CEYaf9NA4J_2u1cqsikYvtR7nz=FEiwAxsKMLSREDhCg@mail.gmail.com>
Duy Nguyen <pclouds@gmail.com> writes:
Show 11 quoted lines
> On Mon, Dec 21, 2015 at 6:01 PM, Philip Oakley <philipoakley@iee.org> wrote:
>> On the Git User's list, Diego J. reported that:
>>
>> 'When I "checkout" a branch using different Upper Case/Lower Case than the
>> original, the branch doesn't show in "git branch [--list]"' [1]
>>
>> While case sensitivity for filenames is a common issue on Windows and the
>> like, I haven't seen any discussion regarding ref name sensitivity - any
>> pointers to past discussions?
>
> Multiple ref backend [1] should solve this.

Yup, I had the same reaction. Instead of restricting the namespace of branches even on systems that do not have this problem, use a ref backend that is not limited by the underlying filesystem. A much better solution.

In addition to the LMDB backend, it might not be a bad idea to add another filesystem-based backend that encodes the refnames safely on case insensitive or case destroying filesystem. That way, those who do not want an extra dependency but do want case sensitive refnames would have an option, and having two non-default backends with quite different semantics may be a good way to ensure that the API for refs backend is kept sane.

Previous: Duy NguyenNext: Torsten Bögershausen
Message 3 of 5 in “Case insensitive branch names”
  1. Philip OakleyDec 21, 2015
  2. Duy NguyenDec 21, 2015
  3. Junio C HamanoDec 21, 2015
  4. Torsten BögershausenDec 21, 2015
  5. Philip OakleyDec 21, 2015

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.