You know how every time you transfer files from a PC to a Mac via a USB stick you get all these .DS_Store or Trashes files cluttering up your thumb drive? Lifehacker point to a blog post from Macworld which tells you how to get rid of hidden files like these via the Terminal. If you have Leopard (Mac OS 10.5) then open up the Terminal from your Utilities folder in Applications and type:
dot_clean /path/folder. This command will join all .DS_Store files with the ones they correspond to.
Another way to get rid of these hidden files is by using an application built to take care of them. CleanArchiver can create archive files for you whilst excluding icon files and .DS_Store files, so the bundle comes out looking cleaner. Changes tracks the differences in multiple versions of files or folders and can make .DS_Store files immediately visible to you. The best one to take care of these pestering files though would be BlueHarvest. This program can be set to search for hidden files like .DS_Store or Trashes in the folders you tell it to look into. It’ll make sure your drives and servers always stay clean of these unwanted and useless files.