Here is “plister”, a trivially short Nu script that I use to display property lists of all formats. It requires a recent build of Nu with the NSObject readFromPropertyList: extension.
#!/usr/local/bin/nush (set ARGV ((NSProcessInfo processInfo) arguments)) (set filename (ARGV 2)) (puts ((NSObject readFromPropertyList:filename) description))
Here’s an example showing usage:
% plister ~/Library/Preferences/com.apple.AddressBook.plist
{
AB21vCardEncoding = MACINTOSH;
ABAIMInstantVisible = 1;
ABAddressesVisible = 1;
ABCardPaneFrame = "{{322, 0}, {320, 268}}";
ABDefaultAddressCountryCode = us;
ABDefaultLayout = 0;
ABEmailsVisible = 1;
ABGroupsPaneFrame = "{{0, 0}, {160, 268}}";
ABHomePageVisible = 1;
ABImportTipCards = 1;
ABMembersPaneFrame = "{{161, 0}, {160, 268}}";
ABMetaDataChangeCount = 19;
ABNameDisplay = 0;
ABNameSorting = 1;
ABPeopleAlternatePaneWidth = 0;
ABPeopleColumnsWidth = 160;
"ABPhoneFormat-Edited" = 0;
"ABPhoneFormat-Enabled" = 1;
"ABPhoneFormat-PhoneFormatter" = (
"+1-###-###-####",
"1-###-###-####",
"###-###-####",
"###-####"
);
ABPhonesVisible = 1;
ABRelatedRecordsVisible = 1;
ABSeparateWindowsFrames = (
);
ABSeparateWindowsHiddenUIDs = (
);
ABSeparateWindowsUIDs = (
);
ABTextSizeFixed = 1;
"NSWindow Frame ABWindow" = "528 261 642 346 0 0 1440 878 ";
}


2 comments ↓
OK, it spits out XML instead of the older format…
Yes, there’s also a couple of tools from Erica Sadun:
Leave a Comment (sign in with Twitter)