4 ms·
If linux doesn't normalize unicode at all, can you have two different files that look like they are named `josé`, depending on if the é is decomposed or not?
by jrochkind1 6y ago
If linux doesn't normalize unicode at all, can you have two different files that look like they are named `josé`, depending on if the é is decomposed or not?
- chungy 6y agoIf you use a file system that doesn't normalize lookups, yes you can.
- Cloudef 6y agoYes, for linux filenames are just bytes. Apart from / and NUL characters it doesnt care what you give it, nor does it mangle them anyway, its the only sane thing to do.
- Someone 6y agoThe only sane thing to do if you don’t care about how humans (as opposed to nerds) think. In the end, the file system doesn’t exist in isolation, it is there to support users, and most of them won’t care how many bytes “é” takes to store. Unix, by not even defining the way to interpret the bytes of file names (one can’t even assume that names consisting of only bytes that correspond to ASCII letters and digits should be interpreted as ASCII) makes it impossible to show file names to users. That’s insane.
- jolmg 6y ago> The only sane thing to do if you don’t care about how humans (as opposed to nerds) think. At the FS layer, I think that's better. Makes things simpler for programs. For non-techie humans, unicode can be normalized at upper levels, like the GUI file manager or toolkit library that does save dialogs, etc. That's if humans being confused because of lack of normalization of unicode is a real practical issue and not just something that can happen but never does.