Skip to content

Comment on OSX For Hackers

Comments

If you are worried about some of these settings before running them, you can backup your preference files

All that the 'defaults' command does is alter values stored in plist files, which are located in /Library/Preferences (and for the user in ~/Library/Preferences).

You can add something like this to the top of the script:

    echo "Making a backup.."
    tar -pzcf ~/preferences-`date "+%Y%m%d-%H%M%S"`.tgz ~/Library/Preferences /Library/Preferences
You may need to sudo to read some of the machine plist files

This is what I was looking for. Thanks!

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.