@jasonfoley76
AppleScript should be just fine. The primary difference between it and shell scripting is that AppleScript is geared toward running while a user is logged in. Since it's getting called from a LaunchAgent, which means someone is logged in, then it's just as applicable.
And, @donmontalvo...
<shakes head />
I've been trying to use Managed Preferences for Lync, I've downloaded the manifest from jamfnation and created a policy but it does nothing. The MicrosoftLyncRegistrationDB.plist file ends up in Library/Managed Preferences but this has no impact. If I move that file just to Preferences it works -what gives?
Our well meaning but probably daft corporate people want us to manage all the preferences under "History" to be unticked. That is: "save conversations locally" "save instant message conv… history folder" and "Save call logs… history folder" all off.
Anyone else been asked to do this? A long shot - just if you had… how did you do it? It's not covered by those ^^ manifests. (Or is it??)
(Digging into the plists unearths a load of crazy - some of which is shown in those manifests - thanks to whoever compiled those)
I don't have a direct answer, but perhaps compare the plist file before and after ticking the preference and see what changes. If you are using Mavericks or Yosemite you may have to wait a bit for cprefsd to copy the setting down so perhaps testing may be easier in Mountain Lion or even Lion (both of which should support Lync).
@alan.trewartha, I've posted the current version of the AppleScript Launcher app I use: https://github.com/macmule/Lync-Launcher/blob/master/LyncLauncher.scpt
There is a key there to save the conversation history.
Cheers both. I did indeed do a plist comparison and found the "SaveConversation -bool" (the one in your script Ben). That appears to fix one of the three history options - but I couldn't find any sign of where the other 2 option states are recorded at all - weird.
What they want are all 3 options fixed off with no manual override possible. I'll give it another fiddle soon. (There's some chance they will give up caring. Frankly I find it a bit creepy they even want this - as a user/employee, not as an IT person)
can any of this be done with config profiles now?