This website uses cookies for analytics purposes and to provide better user experience, read more.

 

Prevent DS_Store file creation

Often happens to those who use a Mac and share files with Windows to sow folders and archives with .DS_Store files.

What are they?

These files are Mac OS X Finder internal documents. You can find them everywhere, in every single folder because they contain information about icons position, windows width and other display options. They are usually harmless because the Finder does not show all files whose name starts with a “dot”. When we start sharing documents on remote folders some problems may arise... Windows Explorer, for example, shows them and their presence may annoy other users.

How to get rid of them?

Unfortunately there is no way to prevent them from being created in normal folders as their presence is essential for the Finder. What you can do, however, is to avoid that they appear on network disks, so that non-Mac users may keep their room tidy. To achieve this, simply open a Terminal (Applications > Utilities > Terminal) and copy the following command:

defaults write com.apple.desktopservices DSDontWriteNetworkStores true

Once you press enter remote folders will be immune to .DS_Store invasion.