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

Re: [PATCH] fast-import.c: always honor the filename case

From
Jeff King <peff@peff.net>
Date
Feb 2, 2014, 23:00 UTC
Message-ID
<20140202230038.GB16196@sigill.intra.peff.net>
In-Reply-To
<1391346784-11891-1-git-send-email-reubenhwk@gmail.com>
[+cc Joshua Jensen, who wrote 50906e0]
On Sun, Feb 02, 2014 at 07:13:04AM -0600, Reuben Hawkins wrote:
> fast-import should not use strncmp_icase.

I am not sure of that. My gut feeling is that core.ignorecase is completely about the _filesystem_, and that git should generally be case-sensitive internally. But I do not know that everyone agrees. Your commit is basically a revert of 50906e0 (Support case folding in git fast-import when core.ignorecase=true, 2010-10-03). And here's some additional discussion specifically regarding fast-import:

  http://thread.gmane.org/gmane.comp.version-control.git/200597
So I think there is a discussion to be had[1].
Show 10 quoted lines
> When it does, files with
> similar names, but different case can be lost in the import.  For
> example...
> 
> M 100644 :1 FileName.txt
> D Filename.txt
> 
> ...would end up deleting FileName from the index during the fast-
> import when strncmp_icase is used and core.ignorecase=true.  The
> intent in the above snippet is to rename the file, not delete it.

There may be a separate bug where fast-import needs to be smarter about ordering operations in such a case (or perhaps fast-export generators need to be more careful about the order of their output). But it might be fixable without disabling case-insensitivity entirely.

-Peff
[1] I am mostly trying to connect people on various sides of the
    discussion here. So take my "gut feeling" above with a grain of
    salt, as it does not come from experience nor thinking too hard
    about the issue.
Previous: Torsten BögershausenNext: Junio C Hamano
Message 3 of 9 in “fast-import.c: always honor the filename case”
  1. fast-import.c: always honor the filename caseReuben Hawkins, Feb 2, 2014
  2. Torsten BögershausenFeb 2, 2014
  3. Jeff KingFeb 2, 2014
  4. Junio C HamanoFeb 3, 2014
  5. Torsten BögershausenFeb 3, 2014
  6. Junio C HamanoFeb 4, 2014
  7. Torsten BögershausenFeb 5, 2014
  8. Torsten BögershausenFeb 9, 2014
  9. Torsten BögershausenFeb 11, 2014

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.