Wednesday, July 3, 2024

On the Origins of .DS_Store

Arno Gourdol (2006, via Lobsters):

However, we soon started realizing that the Finder backend would be useful outside of the Finder. Therefore, a plan was hatched to someday make it available as a public API. Since I had previously been responsible for naming Icon Services and Navigation Services, we decided to go with Desktop Services (at the time, we were also considering renaming the Finder to “Desktop”). Hence the name of the .DS_Store, for “Desktop Services Store”. We added a “.” in front of it so that it would be considered as an invisible file by Unix OS, including Mac OS.


There is also an unfortunate bug that is not fixed to this day that result in an excessive creation of .DS_Store file. Those files should only be created if the user actually makes adjustments to the view settings or set a manual location for icons in a folder. That’s unfortunately not what happens and visiting a folder pretty much guarantees that a .DS_Store file will get created.

With early versions of Mac OS X, the file handling APIs behaved very differently from the corresponding operations in Finder. For example, NSFileManager would discard metadata such as resource forks and Finder/Spotlight comments when copying a file, and there was no API (other than AppleScript) for apps to do the latter themselves. These particular issues were eventually fixed, but Desktop Services never became public, and there remains no API for much of the Finder backend or what’s in the .DS_Store files.


Update (2024-07-04): See also: Hacker News.

Comments RSS · Twitter · Mastodon

Leave a Comment