Apply volume icons the Unix way

Sep 21, '06 07:30:04AM

Contributed by: Anonymous

Well, some of us might be aware of copying and pasting of icons onto volumes. I used to do that, but for whatever reason, I would often just get the plain old "ICNS document" icon instead. So if you try to change the icon of a volume and it simply fails every time, there's a trick.

So what's the trick?

The way OS X stores custom icons is by having an actual icns file on the volume. That icon is a dotfile, meaning that its name starts with a dot, which traditionally means it should be invisible. You can copy icns files into target folders and volumes under the names they are expected to have simply by using the Terminal. Open up a Terminal window and do the following:

cp /path/to/icon.icns /Volumes/volume_name/.VolumeIcon.icns
So if you have a stubborn icon that just doesn't want to be applied, there you have it, a solution.

[robg adds: Note that if your volume name includes a space, you'll either have to place the second part of the above command in quotes, or escape the spaces with backslashes.]

Comments (1)


Mac OS X Hints
http://hints.macworld.com/article.php?story=20060917093255658