<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><div>On Jan 30, 2010, at 2:01 PM, Peter Dyballa wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div><br>Am 30.01.2010 um 18:56 schrieb Alan Munn:<br><br><blockquote type="cite">Second, is is possible to add plist items via a script?<br></blockquote><br><br>Of course! There is the defaults programme. For non-preferences files you need to give it the whole pathname but leave away the extension, for example:<br><br><span class="Apple-tab-span" style="white-space:pre">        </span>defaults read ~/Library/TeXShop/Latex_Macros<br><br>And the same way you can write to it, delete settings from it...<br></div></blockquote><div><br></div><div>On Jan 30, 2010, at 1:06 PM, Adam R. Maxwell wrote:</div><div><br></div><blockquote type="cite"><div>It's possible, but using a shell script with typical tools (sed/awk) has a lot of potential to corrupt the file (especially if it's a binary plist!). I'd use python and plistlib or PyObjC to do it…which still might not work if TeXShop had the file open for some reason.</div></blockquote><br></div><div>Thanks Pete and Adam.  Your worries, Adam were exactly what I had in mind.</div><div><br></div><div>But Dick thinks it's a good idea to add the script to the TeXShop distribution, so that's what we'll do, and I'll avoid the whole issue.  The script will still be available on CTAN for anyone who wants to use it with other editors.</div><div><br></div><div>Thanks</div><div><br></div><div>Alan</div><div><br></div><div><br></div><div apple-content-edited="true"> <span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: 'Lucida Grande'; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div>-- </div><div>Alan Munn</div><div><a href="mailto:amunn@gmx.com">amunn@gmx.com</a></div><div><br></div></div></span><br class="Apple-interchange-newline"></div></span><br class="Apple-interchange-newline"> </div><br></body></html>