I'm trying to update a plist file using bash. For some strings I can update the plist file, but for some strings I get an error. For eg
defaults write '/Users/test/Desktop/myPlist' 'My Key' "[My Value]"
throws an error
2011-08-10 18:49:36.208 defaults[17287:903] Could not parse: [My Value]. Try single-quoting it.
Looks like the characters '[' and ']' seem to be throwing it off. How to make this work with the string "[My Value]"?