Posted
15 Nov 2007 @ 13:08

Categories
,

Comments
14 Comments

Author
Alex

Setting Hard Drive Icons In OS X

Another day and I’m finally getting around to writing another tutorial. This time I thought I concentrate on something I’ve had quite a lot of emails about, ’you’ve given me the icons, how do I go about using them’. I suppose it’s quite an important thing, if your supplying people with something, to tell them how to use it. (Warning: this is a Mac only tutorial).

In previous version of Mac OS X, before Leopard you could get away with applying HD icons though copy and paste alone, and from that point on everything would work fine. Unfortunately, one of the first things I noticed about applying HD icons in Leopard is that copy and paste gives bad results, especially for the scaled down versions of the icon in the new Finder sidebar.

I eventually found the correct way to apply the icons, it involves a little bit of Terminal usage but don’t be afraid. (I have a sneaking suspicion you may also need the Apple Developer Tools installed, these should have been included on your Leopard DVD). I believe this tutorial also applies to setting HD icons on previous versions of Mac OS X.

The first command we will execute in the Terminal copies the icon resource (.icns file) to the correct place on the target HD. You will need to fill in the paths in a way suitable for your system but you can do this by dragging and dropping onto the terminal window.

sudo cp -f /Path_to_Icon/icon_file.icns /Path_to_Drive_Root/.VolumeIcon.icns

Not too difficult was it. The next line will tell the HD to accept a thrid-party icon.

sudo SetFile -a C /Path_to_Drive_Root

The final line will restart the Finder so you can see the changes.

killall Finder

And that’s it. You should see your new icon in the Finder and the correct scaled down version in the Finder sidebar.

Hope you get it working. Check back soon.

Update: After many emails I have written a small utility called Set Icon that automates this process, if you are not feeling confident with the Terminal commands you can download it here.

Update: I’ve just got my hands on a copy of Snow Leopard and the above instructions still seem to work correctly, happy icon changing.

Avatar

peter bradbury - 24 Feb 2009 @ 01:16

Hey i love the images, but theres a heaps easier way of changing your hardrive picture.

All you do is open the desired picture in preview. click and drag the marker around the image.

then command C.

then highlight your HD and press command i

click in the HD image in top left bar and press command v

Avatar

Alex - 07 Apr 2009 @ 00:06

Hi, the copy & paste method used to work great under Panther and Tiger but under Leopard the icons always seemed (at least to me) to be of lower quality when using the copy & paste method compared to the command line method, hence the short tutorial to show how to set the icons using the command line.

Avatar

Andy - 24 Jun 2009 @ 19:44

Hi,

I used your method/also the small program that you have written. But i dont get to see the icon. I get a preview image, with PNG slashed across is. What am i doing wrong?

Avatar

Andy - 24 Jun 2009 @ 20:15

Here is a link to the my desktop/screenshot.

As you can see, I can’t see the icon. Something’s wrong isnt it?
Lemme know what can I do to sort this out.

Thanks for the icon btw.

- Andy!

Avatar

Andy - 24 Jun 2009 @ 20:16

http://picasaweb.google.com/lh/photo/EuDXlb3tTwFKA5F7pnjQ-Q?feat=directlink

Sorry, forgot to attach the link. Apologies for the multiple comments

Avatar

Alex - 25 Jul 2009 @ 18:22

I’m not sure what’s going on, I have a little more time on my hands now I’m not so snowed under with work so I’ll get going with some bug-fixes.

Avatar

Ken - 11 Sep 2009 @ 03:38

I like FastIcns: http://projects.digitalwaters.net/index.php?q=fasticns . Don’t know if it still works in SL.

Avatar

Gary Archer - 20 Oct 2009 @ 23:13

Where is SetFIle? I tried it with my SL installation and i got sudo: Setfile: command not found. Is it one of the Xcode utilities. It worked without it, perhaps because I once had candybar installed?

Gary

Avatar

Iain - 24 Oct 2009 @ 00:30

I have been trying to use the icons which came with my WD external storage drives. It’s easy to ‘cut and paste’ them but it doesn’t fully work – the icons are there visually but you can’t drag them to the trash or double click to open them (I have a G5 Mac Intel). The problem seems to be that the icons don’t really exist on the desktop and when you click on them you are actually clicking on the desktop below. The only way to open/eject them is using the finder menu. This is workable but clunky

I downloaded the ‘Set Icon’ application -it’s great but it only seems to identify the hard drive and not the two external storage devices so I’m no further ahead. I’m just about to abandon this and use another icon set for these drives which I can apply using ‘cut and paste’ and gives me full functionality but I rather like the WD icons as it’s easier to identify which drive is which. Any thoughts before I go to plan B – another icon set?

Iain

Avatar

Alex - 05 Nov 2009 @ 10:27

Gary Archer:

SetFile is installed along with Xcode but I think you are right, it appears to have worked correctly because you at some point had CandyBar installed which enabled the hard drive to have custom icons.

Iain:

I’m sorry to hear you’ve been having problems, I’ll take a look into the bug in ‘Set Icon’ with regards to it not showing external drives.

You should be able to ‘copy and paste’ from either of my icon sets either from the ICNS files opened in Preview or from the ‘Get Info’ window of the icons in the ‘Copy & Paste From Get Info’ folder in the archive.

Avatar

Jon - 08 Nov 2009 @ 13:28

Great icons, nice work. just curious as to how you made the ‘icons’ in the “Copy & Paste From Get Info” folder. they are really easy to use and look great.

Thanks

Avatar

Alex - 01 Dec 2009 @ 20:01

Glad you like the icons Jon, I made the ‘copy & paste’ ones by opening the PNG files in Preview then copying and pasting the image onto an empty folder, simple as that.

Avatar

Peter Breis - 18 Feb 2010 @ 16:33

Thanks for these. They cover some of my HDs but not the series of colored book shaped WD 320Gb Passports.

I’d love to have icons of the Passports identified by their color. Apple manages this with their iPods, I was hoping to do the same. I have six passports: black, silver, red, green, blue and yellow. Usually there at least 2 mounted at a time.

Each contains a specific set of resources/projects so it would be great to quickly identify which I have connected.

Avatar

Peter Breis - 18 Feb 2010 @ 20:41

My apologies I cam here via a google search and subsequently found the Passport icons. Thank you very much! :)






(Not Complulsory)


Preview Comment