Export or list system settings that deviate from defaults

I am looking to generate something similar to this osx settings script. I'm not having any luck finding ways to perform a diff between system defaults and my customized settings.

Anyone know of a command, app, tool, method to generate this?


You might diff the output of defaults read | awk 'length<200' on the current installation and a VM. Or convert the plist files to XML first with something like plutil -convert xml1 ~/Library/Preferences/*.plist.

It would be difficult to do right though:

  • There are probably thousands or tens of thousands of settings that have been changed.
  • Settings are stored in different directories like ~/Library/Preferences/ByHost and ~/Library/Containers/*/Data/Library/Preferences.
  • Many settings are for things like the positions of windows.
  • Some applications like Chrome don't even use the defaults system.
  • Many settings can't be modified with defaults or PlistBuddy.
  • There are a lot of changes between OS X versions.

It's easier to just copy the plist files or recreate settings from GUIs in my opinion.