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

Re: Re-casing directories on case-insensitive systems

From
Kevin Ballard <kevin@sb.org>
Date
Jan 12, 2008, 01:16 UTC
Message-ID
<B2968E86-D43E-4F5E-921F-DF8A15886C98@sb.org>
In-Reply-To
<alpine.LSU.1.00.0801120139170.8333@wbgn129.biozentrum.uni-wuerzburg.de>
On Jan 11, 2008, at 7:40 PM, Johannes Schindelin wrote:
Show 14 quoted lines
> On Fri, 11 Jan 2008, Junio C Hamano wrote:
>
>> Kevin Ballard <kevin@sb.org> writes:
>>
>>> Is there a reason for this? It seems like it would be trivial to end
>>> up with misdiagnosed "untracked" files when using any language other
>>> than English given this behaviuor.
>>
>> No.  The assumption of the code has always been that sane filesystems
>> would return from readdir() the names you gave from creat().
>
> We do not really have to rehash that whole discussion for the Nth  
> time, do
> we?

Apparently so. By Junio's definition, HFS+ is not a sane filesystem, and as git grows more popular with OS X users, this issue is going to crop up more frequently.

According to the HFS+ Volume Format technote[1], filenames in HFS+ are stored in normalized, canonical order. To be more specific, they're stored in a special apple variant of Unicode Normal Form D (the special variant is for preserving round-trip with older encodings with certain codepoint ranges[2]).

In other words, if you hand an HFS+ filesystem a filename that contains unicode characters, what you get back later may be in a different format. And that's going to be a problem if git doesn't deal with this.

[1]: http://developer.apple.com/technotes/tn/tn1150.html#UnicodeSubtleties [2]: http://developer.apple.com/qa/qa2001/qa1173.html

Note: CC list stripped because this is a re-sent email, as the list  
bounced the last one that contained a text/html alternate.
-- 
Kevin Ballard
http://kevin.sb.org
kevin@sb.org
http://www.tildesoft.com
Previous: Johannes SchindelinNext: Junio C Hamano
Message 19 of 29 in “Re-casing directories on case-insensitive systems”
  1. Kevin BallardJan 11, 2008
  2. Kevin BallardJan 11, 2008
  3. Kevin BallardJan 11, 2008
  4. Linus TorvaldsJan 11, 2008
  5. Robin RosenbergJan 11, 2008
  6. Linus TorvaldsJan 11, 2008
  7. Johannes SchindelinJan 11, 2008
  8. Kevin BallardJan 11, 2008
  9. Johannes SchindelinJan 11, 2008
  10. Linus TorvaldsJan 11, 2008
  11. David KastrupJan 11, 2008
  12. Kevin BallardJan 11, 2008
  13. Robin RosenbergJan 11, 2008
  14. Kevin BallardJan 12, 2008
  15. Robin RosenbergJan 12, 2008
  16. Kevin BallardJan 12, 2008
  17. Junio C HamanoJan 12, 2008
  18. Johannes SchindelinJan 12, 2008
  19. Kevin BallardJan 12, 2008
  20. Junio C HamanoJan 12, 2008
  21. Kevin BallardJan 12, 2008
  22. David KastrupJan 12, 2008
  23. Dmitry PotapovJan 12, 2008
  24. Junio C HamanoJan 12, 2008
  25. Robin RosenbergJan 12, 2008
  26. Johannes SchindelinJan 12, 2008
  27. Dmitry PotapovJan 12, 2008
  28. Linus TorvaldsJan 12, 2008
  29. Dmitry PotapovJan 12, 2008

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.