Stop OSX from creating .DS_Store
August 23, 2006 7:51 PM   Subscribe

How can I set Mac OS X so that it doesn't create .DS_Store, .Trashes, and ._* files on USB drives I work with?

I have several USB drives that are all formatted as FAT32, so that I can exchange information with Windows systems.

I'd like to stop OS X from creating these hidden files, since they certainly aren't hidden to Windows. It's even worse when the USB drive is a friend's, and they've never heard of resource forks. What settings can I adjust to stop this?
posted by odinsdream to Computers & Internet (9 answers total) 1 user marked this as a favorite
Heh, you can't. The finder is shit.
This will tell you more.
posted by bonaldi at 7:56 PM on August 23, 2006

I came across that tip in my googling, but, like it says, that's for network volumes.

Barring actually stopping it, can I create a script that activates as part of the Eject action?
posted by odinsdream at 8:06 PM on August 23, 2006

You can also try this.
posted by TheRaven at 8:18 PM on August 23, 2006

Blue Harvest is the solution I use. It's $10.

There are also free items on versiontracker
posted by filmgeek at 8:58 PM on August 23, 2006

Here is a batch file you can run on Windows to set the hidden attribute on all such files.
posted by kindall at 10:32 PM on August 23, 2006

Although it's far more fashionable to bash the Finder than to list actual facts, I will venture to point out that just because the files are visible on Windows does not mean they're expendable. You can delete ".DS_Store" files as long as you don't mind losing Finder window positions and settings, and one can presume ".Trashes" are safe to lose as well.

However, if you have both "filename" and "._filename" in a directory and delete the latter file, you are deleting part of the file that doesn't happy to fit within your destination filesystem's idea of "content." It could be a resource fork, it could be extended attributes, it could be a lot of things, it could be nothing important. It's like opening a file and lopping out a random selection of bytes and thinking nothing bad will happen.

kindall has the right idea - use a batch file so that Windows thinks the hidden items are hidden as well. If you delete parts of your files (and that is what you're doing when you delete "._filename" files, deleting a part of "filename" that doesn't fit in the destination file system's normal data model), then don't be surprised when weird things happen later.

I'm especially unmoved by people who habitually delete ".DS_Store" files and then complain that the Finder never remembers their window positions.
posted by mdeatherage at 10:54 PM on August 23, 2006 [1 favorite]

Is it as fashionable as it is to not read posts, mdeatherage? I certainly offered facts too. Nobody's saying the files are expendable, just that the FF shouldn't leaving them littered about the place.

And you're overstating the importance of resource forks somewhat, I feel. Not only are they very much deprecated, they're usually safe enough to lose. Dropping them is nothing like stripping out a random selection of bytes, although I agree that deleting them is not a Good Thing.
posted by bonaldi at 3:59 AM on August 24, 2006

mdeatherage; thanks for pointing out what to be cautious of. I'm comfortable with these associated risks - I don't work with any filetypes that make use of resource forks on their own, any of these files on the drive would have been created by finder itself setting trivial things that I don't mind losing; especially .Trashes; which I wish weren't there to begin with.
posted by odinsdream at 4:20 AM on August 24, 2006

I also found a guy who compiled a version of the Darwin MS-DOS file system module that automatically set the invisible flag when the Mac is creating files whose names begin with a dot. Unfortunately it was two years ago and the link no longer works. Still, this might be a feasible approach if you have any programming expertise.
posted by kindall at 8:25 AM on August 24, 2006

« Older Is there a delicious pre-mixed cocktail in my...   |   Job Applications + gMail + Thunderbird + PDF = bad... Newer »
This thread is closed to new comments.