One aspect of starting a new development gig is setting up a new development environment and checking out new-to-me code.
At the new shop, I ran into an issue trying to check-out the main Subversion repository on my Mac. Subversion erred out in an images directory half-way through the checkout. The reason is, there are two files with the same name, save for the case in that directory. One is named like foo-bar.jpg, the other is Foo-Bar.jpg.
By default, Mac OS X filesystems are case-retentive, so capitalization within a filename is preserved. However, the default filesystem (HFS+, Journaled) is case-insensitive, so the operating system complains when there are overlapping names like FOO.txt, foo.txt or fOO.TXT
Mac OS X supports case-sensitive filesystems, UFS and HFS+ (Case-sensitive, Journaled)1. A while back, I tried creating a Mac OS X boot volume as HFS+ (Case-sensitive, Journaled). Unfortunately, the installer for Adobe CS3 refused to operate with the case-sensitive filesystem.
So, I’m stuck using the default filesystem. I don’t think having two filenames unique in case only is good practice, but, as previously stated, I sometimes encounter filename overlap in source repositories.
Since I use Leopard, my initial idea was to resize my default partition and create a new, case-sensitive disk partition. The Leopard Disk Utility can resize partitions. This, however, did not solve my problem. While I could create a new partition, I could not change its format.
Idea number two, however, worked. I used Disk Utility to create a 500 megabyte, case-sensitive disk image and saved it to a location in my home directory. Double-clicking on the image mounts it to /Volumes. In Terminal.app, the mounted disk image looks like part of the regular filesystem, allowing me to cd into it and do my Subversion checkout there. Now, I can have overlapping filenames. Moreover, changes to the disk image are saved automatically, so I only need to worry about remounting the disk image after restarts.
These instructions are for Mac OS X Leopard (10.5)