Featured image of post Command to prevent automatic generation of .DS_Store in macOS

Command to prevent automatic generation of .DS_Store in macOS

The command to prevent the automatic generation of .DS_Store on macOS is as follows. Please execute it in the terminal.

1
defaults write com.apple.desktopservices DSDontWriteNetworkStores true

After executing the command, restart Finder.

1
killall Finder

To restore the setting, please run the following command.

1
defaults delete com.apple.desktopservices DSDontWriteNetworkStores false

As with the above, restart Finder after changing the setting.

1
killall Finder
Licensed under CC BY-NC-SA 4.0
comments powered by Disqus