MacOS – Where does OSX store the Desktop layout configuration info

desktopfindermacos

Since early Mac versions, I have been able to rearrange the icons on my desktop. Until I use one of the "Cleanup" options, they can be in pretty much random positions, even overlapping each other. The same layout of of file, directory, and app icons appears on all Desktop/Workspaces.

Where is that information on icon position stored?

What I would like to try doing is having the Desktop folder actually be a symlink that can be set to point to folders Desktop1, Desktop2, etc. I want to use the Current Key app (free) and it's use of AppleScript functions (https://currentkey.com/room-change-alerts/) to change that symlink on the fly, whenever I change desktops, so that I get a different set of icons for each desktop space that I'm in.

I would also like to preserve the layout of each set of desktop icons by also swapping the layout file.

Where can I find that layout file? (If it's a hiddent file in the Desktop directory then I might be home free.)

Thanks.

Best Answer

Mac OS X/macOS stores Finder layout information (including desktop icon placement) within the .DS_Store file that's located inside the current directory.