Re: [egit-dev] Re: jgit problems for file paths with non-ASCII characters
- From
Shawn O. Pearce <spearce@spearce.org>
- Date
- Nov 26, 2009, 19:57 UTC
- Message-ID
- <20091126195736.GV11919@spearce.org>
- In-Reply-To
- <4B0E9F69.9040502@syntevo.com>
Thomas Singer <thomas.singer@syntevo.com> wrote:
Show 7 quoted lines
> > You mean we should do the same thing as Apple with HFS? Are you serious? > > Yes, I'm serious. IMHO there should be a defined clear encoding used for > files names in the repository. Otherwise you don't know what you can expect > by reading it - it could mean anything. File names are in fact strings which > are based on characters. To convert characters to bytes (or visa versa) you > need to know the encoding.
That's likely not going to fly. HFS+ has changed their decomposition rules at least once, which means the byte sequence for the same character sequence would differ, and a tree or commit hash would come out different depending upon which rules you were following. See [1] for details on what HFS+ does.
Also, Linus has previously stated HFS+ chose the worst possible way to encode the names. Getting Linus to admit he was wrong is impossible, getting Linus to accept the HFS+ encoding rules as the standard format used in a Git repository is not likely to happen. Fortunately Linus carries a slightly smaller stick in Git than he used to, but he is quite vocal and people tend to listen.
[1] http://developer.apple.com/mac/library/technotes/tn/tn1150.html#UnicodeSubtleties
-- Shawn.