Mac OS X: checks the syntax of property list files. In your ~/Library/Preferences folder (and in /Library/Preferences) are lots of little XML files that tell apps and system programs how to act. You can read a bit more about them at /MacOSX/configxml.html, at /MacOSX/twosafaris.html and at /Basics/basicxml.html Personally, I have never (yet) had any problem with a preferences file, but it is suggested that you run plutil now and then to verify integrity. To do so, you'd just:
sudo plutil -s ~//Library/Preferences/*.plist /Library/Preferences/*plist
I've also read that plutil can think there's a problem where there is none, though I've never experienced that either. It's not a bad idea to keep safe copies of known good plist files where you cabn get at them quickly if necessary.
This can also convert plist files to a binary format or back to the ordinary text format. Should you every come across a binary format plist, "file" may not recognize it as such:
$ cat foo.plist
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>NSTreatUnknownArgumentsAsOpen</key>
<string>NO</string>
</dict>
</plist>
$ cp foo.plist foosafe.plist
$ file *plist
foo.plist: ASCII text
foosafe.plist: ASCII text
$ plutil -convert binary1 foo.plist
$ file *plist
foo.plist: \<head HTML document text
foosafe.plist: ASCII text
$ od -c foo.plist
0000000 b p l i s t 0 0 321 001 002 _ 020 035 N S
0000020 T r e a t U n k n o w n A r g u
0000040 m e n t s A s O p e n R N O \b 013
0000060 + \0 \0 \0 \0 \0 \0 001 001 \0 \0 \0 \0 \0 \0 \0
0000100 003 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0
0000120 .
0000121
$ plutil -convert xml1 foo.plist
$ diff *.plist
$
Many of the products and books I review are things I purchased for my own use. Some were given to me specifically for the purpose of reviewing them.
I resell or can earn commissions from the sale of some of these items. Links within these pages may be affiliate links that pay me for referring you to them. That's mostly insignificant amounts of money; whenever it is not I have made my relationship plain. I also may own stock in companies mentioned here. If you have any question, please do feel free to contact me.
Have you tried Searching this site?
Unix/Linux/Mac OS X support by phone, email or on-site: Support Rates
This is a Unix/Linux resource website. It contains technical articles about Unix, Linux and general computing related subjects, opinion, news, help files, how-to's, tutorials and more. We appreciate comments and article submissions.
Don't miss responses! Subscribe to Comments by RSS or by Email
Click here to add your comments
If you want a picture to show with your comment, go get a Gravatar