I like to have my Mac desktop clear of any files other than the ones I am working on and haven't placed in folders yet. I also use a separate partition for a swap file. Finally, I often attach an external FireWire drive, which, when present, I would like to have appear on my desktop. Unfortunately, the Finder's "Show these Items on the desktop – Hard Disks" selection gives you all of the disks or none of them.
SetFile can be used, if you have the Developer Tools installed, to hide selected drives. A previous hint from discussed using SetFile to hide the swap partition, but it works on the startup disk as well. In this case, one types:
% SetFile -a V /Volumes/SwapThis makes the swap volume and the root volume invisible, but still shows mounted external hard drives when they are present.
% SetFile -a V /
Mac OS X Hints
http://hints.macworld.com/article.php?story=20020915055100747