I am attempting to manipulate an Adobe Reader plist file on OS X to stop auto update checking.
This needs to be scripting so I can affect the change on 700+ Macs.
I have:
#!/bin/bash
plutil -convert xml1 /Users/username/Library/Preferences/com.adobe.Reader.plist
to convert the file for text editing.
I found this elsewhere for multi-line search and replace:
sed -n '1h;1!H;${;g;s/<h2.*</h2>/No title here/g;p;}' sample.php > sample-edited.php;
The source file has repetitions of similar data, so I need to find the occurrence after the entry CheckForUpdatesAtStartup
Here is a portion of the file:
<key>AutoUriDetect</key>
<array>
<integer>0</integer>
<true/>
</array>
<key>CheckForUpdatesAtStartup</key>
<array>
<integer>0</integer>
<true/>
</array>
<key>CheckGPUAtStartup</key>
<array>
<integer>0</integer>
<false/>
</array>
So I need to replace the true to false for the CheckForUpdatesAtStartup array.
1 Answer