Re: [Pharo-project] FileDirectory default is wrong in MacOS
H Bill. The file system (as much as I can notice) seems to be Mac OS Extended (Journaled). I am a completly mac newbie...so...
Eliot: WOW! I didn't know that you can choose....I am googling now how to change to case sensitive (I hope I don't need to reformat).
you have but don't do that you may get a lot of trouble. Imagine you send me two files which are case sensitive and my system may blow up or I lose something and I send it back to you fucked up.
So if you are ready to not interact with other people change else keep it the way it is.
I got problem because damien in the past changed it and interacted with me.
Ok, thanks for the advice. But still, the problem with Pharo is present.
My OS is case insensitive, but FileDirectory default is working like case sensittive.....
This means that the VM should give a way to know if the filesystem is key sensitive without that we can only guess or we could have a test saving a file and checking.
On Nov 22, 2010, at 12:58 08PM, Stéphane Ducasse wrote:
H Bill. The file system (as much as I can notice) seems to be Mac OS Extended (Journaled). I am a completly mac newbie...so...
Eliot: WOW! I didn't know that you can choose....I am googling now how to change to case sensitive (I hope I don't need to reformat).
you have but don't do that you may get a lot of trouble. Imagine you send me two files which are case sensitive and my system may blow up or I lose something and I send it back to you fucked up.
So if you are ready to not interact with other people change else keep it the way it is.
I got problem because damien in the past changed it and interacted with me.
Ok, thanks for the advice. But still, the problem with Pharo is present.
My OS is case insensitive, but FileDirectory default is working like case sensittive.....
This means that the VM should give a way to know if the filesystem is key sensitive without that we can only guess or we could have a test saving a file and checking.
As a (fragile) hack, you could use isAFileNamed: with a known existing filename on the platform containing uppercase characters i.e. the platform function called in FilePlugin>primitiveFileOpen (at least on Mac) respects the case-sensitivity setting. Problem is when new version come out where the file is moved/removed, you're in trouble :) Cheers, Henry
On Mon, Nov 22, 2010 at 1:16 PM, Henrik Johansen < henrik.s.johansen@veloxit.no> wrote:
On Nov 22, 2010, at 12:58 08PM, Stéphane Ducasse wrote:
H Bill. The file system (as much as I can notice) seems to be Mac OS
Extended (Journaled). I am a completly mac newbie...so...
Eliot: WOW! I didn't know that you can choose....I am googling now how
to change to case sensitive (I hope I don't need to reformat).
you have but don't do that you may get a lot of trouble. Imagine you send me two files which are case sensitive and my system may blow up or I lose something and I send it back to you fucked up.
So if you are ready to not interact with other people change else keep it the way it is.
I got problem because damien in the past changed it and interacted with me.
Ok, thanks for the advice. But still, the problem with Pharo is present.
My OS is case insensitive, but FileDirectory default is working like case sensittive.....
This means that the VM should give a way to know if the filesystem is key sensitive without that we can only guess or we could have a test saving a file and checking.
As a (fragile) hack, you could use isAFileNamed: with a known existing filename on the platform containing uppercase characters i.e. the platform function called in FilePlugin>primitiveFileOpen (at least on Mac) respects the case-sensitivity setting.
Thanks Henry for the workarround. It works.
Problem is when new version come out where the file is moved/removed, you're in trouble :)
Cheers, Henry
Likely a bit of history is needed here. The original file logic for macintosh OS 7.5.5 worked with HFS, later I guess it was 8.x Apple introduced HFS+ which allowed for files names to be longer than N where N was mmm 26 or 32? That would be the check for 255 characters. So we had to deal with pre HFS and post HFS+ systems. Later when os-x came out I had to rewrite the file lookup logic to properly handle symbolic links and os-9 aliases, then earlier in the last decade it became apparent that Apple was moving the developer community from using OS-7.x.x file naming conventions to unix naming convention. So again some nasty bit of logic to help the image and the VM sort between is it HFS, HFS+, pre os-x names, or post os-x names (255 chars & case insensitive). In all this Apple decided to go with case insensitive file names, but on the os-x server case sensitive. Now of course you can switch but that sometimes leads to interesting problems. So one is that you can have four volumes mounted, each of which has different case sensitivity, so it's not the operating system that drives case or no, it's the volume. When I looked at this 10 years back it was *difficult* to drag the information about the volume out of the OS, now it's easier, but mounting NFS etc perhaps makes things a bit fuzzy again. However this issue is a problem because you can't do "FileSystem isCaseSensitive" it's more like "FileSystem isCaseSensitiveForVolume: volume" Clouding that is of course the fact what is a volume across different OS? and of course in unix you can have mount points so it's unclear how you know... Anyway as you see a bit of restructuring would need to be done because you have to consider each file path differently. On 2010-11-22, at 6:11 AM, Mariano Martinez Peck wrote:
Problem is when new version come out where the file is moved/removed, you're in trouble :)
Cheers, Henry
-- =========================================================================== John M. McIntosh <johnmci@smalltalkconsulting.com> Twitter: squeaker68882 Corporate Smalltalk Consulting Ltd. http://www.smalltalkconsulting.com ===========================================================================
On Mon, Nov 22, 2010 at 12:58 PM, Stéphane Ducasse < stephane.ducasse@inria.fr> wrote:
H Bill. The file system (as much as I can notice) seems to be Mac OS
Extended (Journaled). I am a completly mac newbie...so...
Eliot: WOW! I didn't know that you can choose....I am googling now how
to change to case sensitive (I hope I don't need to reformat).
you have but don't do that you may get a lot of trouble. Imagine you send me two files which are case sensitive and my system may blow up or I lose something and I send it back to you fucked up.
So if you are ready to not interact with other people change else keep it the way it is.
I got problem because damien in the past changed it and interacted with me.
Ok, thanks for the advice. But still, the problem with Pharo is present.
My OS is case insensitive, but FileDirectory default is working like case sensittive.....
This means that the VM should give a way to know if the filesystem is key sensitive without that we can only guess or we could have a test saving a file and checking.
I thought about that. I was thinking to implement MacFileDirectory >> isCaseSensitive so that it keeps a class side variable with the boolean. The getter can be lazy, and in nil, you can write a dummy file, and check. But even if you do this, we still have a problem, becuase right now FileDirectory default is answering the unix one....and unix is always case-sensitive, so we shouldn't change that. So first we need to modify so that we can use the MacFileDirectory, and then how to modify it so that it can support both case sensitive, and insensitive.
participants (4)
-
Henrik Johansen -
John M McIntosh -
Mariano Martinez Peck -
Stéphane Ducasse