Skip to content

Instantly share code, notes, and snippets.

@sarcas
sarcas / work_out_plist.sh
Created January 23, 2015 00:13
Trying to automate the updating of the server favourites in Snow Leopard
`PlistBuddy -c "delete :CustomListItems" ~/Library/Preferences/sidebarlists.plist`
`PlistBuddy -c "add :CustomListItems array" ~/Library/Preferences/sidebarlists.plist`
for servername in serverlist
do
`PlistBuddy -c "add :CustomListItems:0 dict"`
`PlistBuddy -c "add :CustomListItems:0:Name string $servername"`
`PlistBuddy -c "add :CustomListItems:0:URL string $servername"`
done