Posted on 03-07-2012 01:28 PM
Anyone able to manage Lync 2011's setting via JAMF MCX?
Or via /Library/Preferences/MicrosoftLyncRegistrationDB.plist?
Or /User/currentuser/Library/Preferences/ByHost/MicrosoftLyncRegistrationDB.<GUID>.plist?
The below link give the managed prefs, & me a headache!
http://mac2.microsoft.com/help/office/14/en-us/lyncdeploy/item/81755f45-3c1b-4d09-bef1-2cf48b9fc29a
Solved! Go to Solution.
Posted on 03-07-2012 02:59 PM
Hey everyone I worked extensively with Microsoft on the Lync machine level Plist issues and we were able to resolve them.
Here is the basics.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Backward_Compatible_Version</key>
<integer>1</integer>
<key>Current_Version</key>
<integer>1</integer>
<key>hkey_local_machine</key>
<string><<MacRegNoValue>></string>
<key>hkey_local_machinesoftware</key>
<string><<MacRegNoValue>></string>
<key>hkey_local_machinesoftwarepolicies</key>
<string><<MacRegNoValue>></string>
<key>hkey_local_machinesoftwarepoliciesmicrosoft</key>
<string><<MacRegNoValue>></string>
<key>hkey_local_machinesoftwarepoliciesmicrosoftcommunicator</key>
<string><<MacRegNoValue>></string>
<key>hkey_local_machinesoftwarepoliciesmicrosoftcommunicatorconfigurationmode</key>
<integer>1</integer>
<key>hkey_local_machinesoftwarepoliciesmicrosoftcommunicatorserveraddressinternal</key>
<string>domain.com</string>
<key>hkey_local_machinesoftwarepoliciesmicrosoftcommunicatorserveraddressexternal</key>
<string>domain.com</string>
</dict>
</plist>
Posted on 02-03-2015 11:32 AM
@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.
Posted on 03-07-2012 02:28 PM
I know MS released a white paper how to manage all of the prefs. I don't manage ours unfortunately. Users just login and I believe most of the other settings are handled by the server.
Posted on 03-07-2012 02:36 PM
Yes, you want to look at the white paper instead for this (and Communicator).
http://www.microsoft.com/download/en/details.aspx?id=27559
The Managed Preferences section on page 10 is the same information but a little easier on the eyes. What MCX can't do for you is set user variables such as user name and email address. I'm using a launchd item to set this for users so that their first run experience consists of simply clicking the Sign In button.
Posted on 03-07-2012 02:40 PM
Dave Castelletti described how he was managing Lync's username and password settings here:
http://thisisdave.posterous.com/creating-a-customized-microsoft-lync-2011-ins
Posted on 03-07-2012 02:59 PM
Hey everyone I worked extensively with Microsoft on the Lync machine level Plist issues and we were able to resolve them.
Here is the basics.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Backward_Compatible_Version</key>
<integer>1</integer>
<key>Current_Version</key>
<integer>1</integer>
<key>hkey_local_machine</key>
<string><<MacRegNoValue>></string>
<key>hkey_local_machinesoftware</key>
<string><<MacRegNoValue>></string>
<key>hkey_local_machinesoftwarepolicies</key>
<string><<MacRegNoValue>></string>
<key>hkey_local_machinesoftwarepoliciesmicrosoft</key>
<string><<MacRegNoValue>></string>
<key>hkey_local_machinesoftwarepoliciesmicrosoftcommunicator</key>
<string><<MacRegNoValue>></string>
<key>hkey_local_machinesoftwarepoliciesmicrosoftcommunicatorconfigurationmode</key>
<integer>1</integer>
<key>hkey_local_machinesoftwarepoliciesmicrosoftcommunicatorserveraddressinternal</key>
<string>domain.com</string>
<key>hkey_local_machinesoftwarepoliciesmicrosoftcommunicatorserveraddressexternal</key>
<string>domain.com</string>
</dict>
</plist>
Posted on 03-07-2012 03:18 PM
Thanks Matt, copied yours... Changed domain.com to my server.. added to /Library/Preferences/.. launched Lync.. & no change??
Have i missed something?
<? xml version="1.0" encoding="UTF-8"?>.
<! DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">.
<plist version="1.0">
<dict>
<key>Backward_Compatible_Version</key>
<integer>1</integer>
<key>Current_Version</key>
<integer>1</integer>
<key>hkey_local_machine</key>
<string><<MacRegNoValue>></string>
<key>hkey_local_machinesoftware</key>
<string><<MacRegNoValue>></string>
<key>hkey_local_machinesoftwarepolicies</key>
<string><<MacRegNoValue>></string>
<key>hkey_local_machinesoftwarepoliciesmicrosoft</key>
<string><<MacRegNoValue>></string>
<key>hkey_local_machinesoftwarepoliciesmicrosoftcommunicator</key>
<string><<MacRegNoValue>></string>
<key>hkey_local_machinesoftwarepoliciesmicrosoftcommunicatordisableservercheck</key>
<integer>1</integer>
<key>hkey_local_machinesoftwarepoliciesmicrosoftcommunicatorconfigurationmode</key>
<integer>1</integer>
<key>hkey_local_machinesoftwarepoliciesmicrosoftcommunicatorserveraddressinternal</key>
<string>LS-LYNCSTD-01.pentland.com</string>
<key>hkey_local_machinesoftwarepoliciesmicrosoftcommunicatorserveraddressexternal</key>
<string>LS-LYNCSTD-01.pentland.com</string>
</dict>
</plist>
Posted on 03-07-2012 03:22 PM
Would've helped if i'd copied the plist from you correctly Matt!
Thanks!
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Backward_Compatible_Version</key>
<integer>1</integer>
<key>Current_Version</key>
<integer>1</integer>
<key>hkey_local_machine</key>
<string><<MacRegNoValue>></string>
<key>hkey_local_machinesoftware</key>
<string><<MacRegNoValue>></string>
<key>hkey_local_machinesoftwarepolicies</key>
<string><<MacRegNoValue>></string>
<key>hkey_local_machinesoftwarepoliciesmicrosoft</key>
<string><<MacRegNoValue>></string>
<key>hkey_local_machinesoftwarepoliciesmicrosoftcommunicator</key>
<string><<MacRegNoValue>></string>
<key>hkey_local_machinesoftwarepoliciesmicrosoftcommunicatorconfigurationmode</key>
<integer>1</integer>
<key>hkey_local_machinesoftwarepoliciesmicrosoftcommunicatorserveraddressinternal</key>
<string>LS-LYNCSTD-01.pentland.com</string>
<key>hkey_local_machinesoftwarepoliciesmicrosoftcommunicatorserveraddressexternal</key>
<string>LS-LYNCSTD-01.pentland.com</string>
</dict>
</plist>
Posted on 03-07-2012 04:23 PM
I'm using a launchd item to set this for users so that their first run experience consists of simply clicking the Sign In button.
I would really like to see how you are doing this. Is it similar to your Outlook script?
Posted on 03-07-2012 10:39 PM
+1 to Jason's request.
I'm guessing it's a combo of launchd, dscl & defaults/PlistBuddy.
Posted on 03-08-2012 06:47 AM
If you are using Kerberos you can trigger the Kerberos flag in the plist and that will allow 1 click sign on.
Posted on 03-08-2012 08:06 AM
My fault for not being clearer when I said this. I'm in the middle of a Messenger --> Communicator --> Lync migration and I've got both Lync and Communicator on my brain. My script is for Communicator not Lync. However, maybe it's still useful for Lync.
Script: https://gist.github.com/1996861
Launchd agent: https://gist.github.com/2001539
The launchd agent runs at every login to call the script. The script checks for the existence of the current user's ~/Library/Preferences/com.microsoft.Communicator.plist preference file. If that exists then the script exits. Otherwise, it uses id to get the user's name and dscl to get the user's email address from Active Directory. The defaults command creates and populates the preference file with the information.
Posted on 03-08-2012 11:22 AM
William,
I'm writing a "Lync Launcher" AppleScript app that will create the plist with the users sip address from dscl, enable Kerberos auth, copies old communicator convesations & sets conversations to always be ticked.
Plus a launch agent to run the thing @ login.
I'll post a link about it when done. (hopefully Monday latest).
Posted on 03-09-2012 04:08 PM
With help from Jason Bush I was able to modify my Communicator script for Lync. It is written for Active Directory environments and should support Mac OS X 10.5.8 and higher.
The following launchd agent and script will pre-populate a user's name and email address for Microsoft Lync.
Script: https://gist.github.com/2009272
Launchd agent: https://gist.github.com/2009385
Instructions:
The launchd agent will launch the script at every user login. If it finds ~/Library/Preferences/com.microsoft.Lync.plist then the script will exit. Otherwise, it will do the following:
1. Determine the current Mac OS version
1. Get user's current login name
1. Read Active Directory for the user's email address
1. Populate the user's ~/Library/Preferences/com.microsoft.Lync.plist file with the Lync logon information.
1. Set the preference to not show the license agreement.
1. Write details of the setup to ~/Library/Logs/LyncSetup.log.
Posted on 03-10-2012 03:49 PM
Thanks WIll.
My script is below, it's a little bit more involved as it queries DSCL for the domain info, users e-mail, users kerberos ID & users SIP Address.
As well as enabling kerberos auth etc..
Sadly, It looks like we cannot use auto discover to setup Lync or Oulook Mac Clients. i'm awaiting time with our exchange guy to sort.
(I've been trying to get you exchange scripts working too, yet they will not when using Kerberos.. so something it up).
Incidentally, where did you find the "acceptedSLT140" key?
I will flesh out this when finished.
--------------------------------------------------------------------------------------------------------------------------
set loggedInUser to do shell script "whoami"
set accountType to do shell script "dscl . -read /Users/" & loggedInUser & " | ?grep UniqueID | cut -c 11-"
set nodeName to do shell script "dscl . -read /Users/" & loggedInUser & " | awk '/^OriginalNodeName:/,/^Password:/' | head -2 | tail -1 | cut -c 2-"
set userHome to do shell script "dscl . -read /Users/" & loggedInUser & " | grep OriginalNFSHomeDirectory | awk '{print $2}'"
set dsclSIPAddress to do shell script "dscl " & quoted form of nodeName & " -read /Users/" & loggedInUser & " | grep dsAttrTypeNative:msRTCSIP-PrimaryUserAddress: | awk '{print $2}'"
set emailAddress to do shell script "dscl . -read /Users/" & loggedInUser & " EMailAddress | awk 'BEGIN {FS=": "} {print $2}'"
set OSVersion to do shell script "/usr/bin/defaults read /System/Library/CoreServices/SystemVersion ProductVersion | awk '{print substr($1,1,4)}'"
-- Checks Group Membership for ADGroups contains user & if they
--Checks to see if account is an AD Account, if it's not exits
if accountType is less than 1000 then
tell me to quit
end if
if (OSVersion is equal to "10.5") or (OSVersion is equal to "10.6") then
set kerberosID to do shell script "klist | head -2 | tail -1 | awk '{print $3}'"
else
set kerberosID to do shell script "klist | head -2 | tail -1 | awk '{print $2}'"
end if
if word 1 of kerberosID is equal to "klist:" then
tell me to quit
end if
set the caseSIP to change_case(dsclSIPAddress, 0)
set the userSIP to replace_chars(caseSIP, "@", "(at)")
set the lyncPLISTSIP to replace_chars(userSIP, ".", "(dot)")
do shell script "defaults write /Users/" & loggedInUser & "/Library/Preferences/com.microsoft.Lync acceptedSLT140 -bool true"
do shell script "defaults write /Users/" & loggedInUser & "/Library/Preferences/com.microsoft.Lync AutoConfigProxy -bool true"
do shell script "defaults write /Users/" & loggedInUser & "/Library/Preferences/com.microsoft.Lync KerberosID " & emailAddress
do shell script "defaults write /Users/" & loggedInUser & "/Library/Preferences/com.microsoft.Lync UserHasRunMessenger140 -bool true"
do shell script "defaults write /Users/" & loggedInUser & "/Library/Preferences/com.microsoft.Lync UserIDMRU -array-add '{ LogonName="" & loggedInUser & ""; UserID="" & emailAddress & "";}'"
do shell script "defaults write /Users/" & loggedInUser & "/Library/Preferences/com.microsoft.Lync UseKerberos -bool true"
do shell script "defaults write /Users/" & loggedInUser & "/Library/Preferences/com.microsoft.Lync UserLogonName " & kerberosID
do shell script "defaults write /Users/" & loggedInUser & "/Library/Preferences/com.microsoft.Lync " & quoted form of lyncPLISTSIP & " -dict ArchiveAutomatically -bool true PictureView -bool true SaveConversation -bool true ShowSaveReminder -bool false"
tell application "Microsoft Lync"
activate
end tell
on replace_chars(this_text, search_string, replacement_string)
set AppleScript's text item delimiters to the search_string
set the item_list to every text item of this_text
set AppleScript's text item delimiters to the replacement_string
set this_text to the item_list as string
set AppleScript's text item delimiters to ""
return this_text
end replace_chars
on change_case(this_text, this_case)
if this_case is 0 then
set the comparison_string to "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
set the source_string to "abcdefghijklmnopqrstuvwxyz"
else
set the comparison_string to "abcdefghijklmnopqrstuvwxyz"
set the source_string to "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
end if
set the new_text to ""
repeat with this_char in this_text
set x to the offset of this_char in the comparison_string
if x is not 0 then
set the new_text to (the new_text & character x of the source_string) as string
else
set the new_text to (the new_text & this_char) as string
end if
end repeat
return the new_text
end change_case
Posted on 03-12-2012 08:40 AM
(I've been trying to get you exchange scripts working too, yet they will not when using Kerberos.. so something it up).
Hi Ben!
If the Exchange scripts configure the account properly for Kerberos then they've done their work. They can't make Kerberos work. If they're not configuring your account properly for Kerberos then get with me and we'll get it fixed. You can reach me at bill at officeformachelp.com.
Posted on 04-24-2012 11:23 AM
anyone knows how to disable 2 pop up windows for asking "Would you like Lync to be the default app" ?
Posted on 04-26-2012 08:36 AM
MANY thanks to Ben for his very helpful apple script. It worked perfectly for me once I performed a couple of edits, which are called out in the full edited code below. I thought I'd share in case it's helpful to others.
Namely, the lyncPLISTSIP variable didn't seem to work for me (it would return a blank value) so I created a new variable called shortEmailAddress which works perfectly by just grabbing the first part of a user's email address before the "@" sign. Due to this change, some parts of the original code might be superflous, but since this is working great for me I just left everything in there from the original code.
I also wanted to show the contact groups that were defined, so I had to set the GroupMode key to a value of "1" as it defaults to a value of "0".
Thanks again Ben!
Justin
--------------------------------------------------------------------------------------------------------------------------
set loggedInUser to do shell script "whoami"
set accountType to do shell script "dscl . -read /Users/" & loggedInUser & " | ?grep UniqueID | cut -c 11-"
set nodeName to do shell script "dscl . -read /Users/" & loggedInUser & " | awk '/^OriginalNodeName:/,/^Password:/' | head -2 | tail -1 | cut -c 2-"
set userHome to do shell script "dscl . -read /Users/" & loggedInUser & " | grep OriginalNFSHomeDirectory | awk '{print $2}'"
set dsclSIPAddress to do shell script "dscl " & quoted form of nodeName & " -read /Users/" & loggedInUser & " | grep dsAttrTypeNative:msRTCSIP-PrimaryUserAddress: | awk '{print $2}'"
set emailAddress to do shell script "dscl . -read /Users/" & loggedInUser & " EMailAddress | awk 'BEGIN {FS=": "} {print $2}'"
set OSVersion to do shell script "/usr/bin/defaults read /System/Library/CoreServices/SystemVersion ProductVersion | awk '{print substr($1,1,4)}'"
-- Checks Group Membership for ADGroups contains user & if they
--Checks to see if account is an AD Account, if it's not exits
if accountType is less than 1000 then
tell me to quit
end if
if (OSVersion is equal to "10.5") or (OSVersion is equal to "10.6") then
set kerberosID to do shell script "klist | head -2 | tail -1 | awk '{print $3}'"
else
set kerberosID to do shell script "klist | head -2 | tail -1 | awk '{print $2}'"
end if
if word 1 of kerberosID is equal to "klist:" then
tell me to quit
end if
set the caseSIP to change_case(dsclSIPAddress, 0)
set the userSIP to replace_chars(caseSIP, "@", "(at)")
set the lyncPLISTSIP to replace_chars(userSIP, ".", "(dot)")
-- EDIT FROM ORIGINAL: I'm defining this variable called shortEmailAddress to fix problems I had with the lyncPLISTSIP variable which wasn't working for me. It left the key name blank where it was called below so I'm doing it this way.
set AppleScript's text item delimiters to "@"
set shortEmailAddress to (text item 1 of emailAddress) as text
do shell script "defaults write /Users/" & loggedInUser & "/Library/Preferences/com.microsoft.Lync acceptedSLT140 -bool true"
do shell script "defaults write /Users/" & loggedInUser & "/Library/Preferences/com.microsoft.Lync AutoConfigProxy -bool true"
do shell script "defaults write /Users/" & loggedInUser & "/Library/Preferences/com.microsoft.Lync KerberosID " & emailAddress
do shell script "defaults write /Users/" & loggedInUser & "/Library/Preferences/com.microsoft.Lync UserHasRunMessenger140 -bool true"
do shell script "defaults write /Users/" & loggedInUser & "/Library/Preferences/com.microsoft.Lync UserIDMRU -array-add '{ LogonName="" & loggedInUser & ""; UserID="" & emailAddress & "";}'"
do shell script "defaults write /Users/" & loggedInUser & "/Library/Preferences/com.microsoft.Lync UseKerberos -bool true"
do shell script "defaults write /Users/" & loggedInUser & "/Library/Preferences/com.microsoft.Lync UserLogonName " & kerberosID
-- EDIT FROM ORIGINAL: replacing this original command with the one directly below it. The lyncPLISTSIP variable wasn't working for me and simply left the key with a blank name. Using the variable called shortEmailAddress defined above I fixed that issue
-- do shell script "defaults write /Users/" & loggedInUser & "/Library/Preferences/com.microsoft.Lync " & quoted form of lyncPLISTSIP & " -dict ArchiveAutomatically -bool true PictureView -bool true SaveConversation -bool true ShowSaveReminder -bool false"
do shell script "defaults write /Users/" & loggedInUser & "/Library/Preferences/com.microsoft.Lync sip:" & quoted form of shortEmailAddress & quoted form of "(" & "at" & quoted form of ")" & "serinocoyne" & quoted form of "(" & "dot" & quoted form of ")" & "com -dict ArchiveAutomatically -bool true PictureView -bool true SaveConversation -bool true ShowSaveReminder -bool false ShowOfflineContacts -bool false"
-- EDIT FROM ORIGINAL: adding this line which displays contact groups, otherwise they're hidden
do shell script "defaults write /Users/" & loggedInUser & "/Library/Preferences/com.microsoft.Lync GroupMode -int 1"
tell application "Microsoft Lync"
activate
end tell
on replace_chars(this_text, search_string, replacement_string)
set AppleScript's text item delimiters to the search_string
set the item_list to every text item of this_text
set AppleScript's text item delimiters to the replacement_string
set this_text to the item_list as string
set AppleScript's text item delimiters to ""
return this_text
end replace_chars
on change_case(this_text, this_case)
if this_case is 0 then
set the comparison_string to "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
set the source_string to "abcdefghijklmnopqrstuvwxyz"
else
set the comparison_string to "abcdefghijklmnopqrstuvwxyz"
set the source_string to "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
end if
set the new_text to ""
repeat with this_char in this_text
set x to the offset of this_char in the comparison_string
if x is not 0 then
set the new_text to (the new_text & character x of the source_string) as string
else
set the new_text to (the new_text & this_char) as string
end if
end repeat
return the new_text
end change_case
Posted on 04-26-2012 11:15 AM
Thanks bentomms and talkingmoose!
I have created the uninstaller script for Lync (its for talkingmoose's solution, but can be customized)
#!/bin/sh
##This will quit Lync if its open
PID=`ps -A | grep Lync | grep -v grep |awk '{print $1}'`
kill -9 $PID
#remove Lync plist from all existing users
UserList=`dscl . list /Users UniqueID | awk '$2 > 500 { print $1 }'`
for u in $UserList ; do
rm /Users/$u/Library/Preferences/com.microsoft.Lync.plist ; done
#remove Lync related launchd
launchctl unload /Library/LaunchAgents/com.mycompany.LyncSetup.plist
/bin/sleep 3
#remove all the Lync related files and folders
rm -R /Applications/Microsoft Lync.app
rm /Library/MYSCRIPTS/LyncSetUp.sh
rm /Library/MYSCRIPTS/lyncloginstart.sh
rm /Library/LaunchAgents/com.mycompany.LyncSetup.plist
exit 0
Posted on 04-04-2013 10:10 AM
Hey everyone,
Great stuff here so far. We've also just uploaded a couple of MCX Manifest files that can be used to set Managed Preferences for Lync. The same requirements apply that you must include the registry key entries in addition to any of the settings you wish to apply.
We hope this helps!
Nick
Posted on 04-18-2013 10:31 AM
Thanks for all this help, I am using the MCX MicrosoftLyncRegistrationDB.manifest attempting to use a managed pref to set the manual server config radial button and to insert the desired server addys. I have it set up and working ( at least the output of the verbose has no errors, but it never actually changes this setting in lync. This is a system wide setting not user. I opened a ticket today with JAMF, but figured I would try here also. Anyone have this working ? I have followed the troubleshooting managed prefs post here but there are no errors etc ?
Posted on 04-18-2013 12:37 PM
@nick wrote:
Hey everyone, Great stuff here so far. We've also just uploaded a couple of MCX Manifest files that can be used to set Managed Preferences for Lync. The same requirements apply that you must include the registry key entries in addition to any of the settings you wish to apply. We hope this helps! Nick
Got Link?
(pun intended)
[UPDATE] Nevermind, just remembered you can look for Microsoft Lync under Third-Party Products, and then click on Managed Preferences:
https://jamfnation.jamfsoftware.com/viewProduct.html?id=145&view=managedPreferences
Thanks,
Don
Posted on 04-22-2013 07:20 PM
Hey guys,
I have not had a chance to try that exact combination of settings at the System Level, but I did try this combination at the User Level and it performed as expected for me. I'm actually unsure why there is a differentiation between System Level and User Level for the Lync preferences since they both end up affecting the user the same way.
Nick
Posted on 05-08-2014 05:34 PM
Hey guys,
Long time listener, first time caller :)
do shell script "defaults write /Users/" & loggedInUser & "/Library/Preferences/com.microsoft.Lync " & quoted form of lyncPLISTSIP & " -dict ArchiveAutomatically -bool true PictureView -bool true SaveConversation -bool true ShowSaveReminder -bool false"
So I saw the "quoted form of lyncPLISTSIP" and it kind of tripped me up. Is there an easy way to run this command from a straight up shell script? I basically want to set all conversations to NOT save (so -bool false). I've been looking all over for this command but instead of running the applescript, I was going to run the shell script + launchd. I want to add this to @talkingmoose 's script. Thanks guys!
Posted on 05-08-2014 07:22 PM
What you've quoted in your post is how AppleScript would call a shell script command. So, all we need to do is remove the AppleScript part of things.
defaults write com.microsoft.Lync SaveConversation -bool false
If the preference file is in the user's own home folder then you have no need to explicitly provide the path "/Users/mmoose/Library/Preferences/com.microsoft.Lync". However, if you prefer to explicity state the path then use the $USER variable. It returns the current user's name.
defaults write "/Users/$USER/Library/Preferences/com.microsoft.Lync" SaveConversation -bool false
Does that get you what you need?
Posted on 05-14-2014 09:01 AM
Thanks @talkingmoose, I had tried that before posting but it didn't get what I needed. I think I am still trying to wrap my head around the concept of dict's in plists (learning a ton on these forums). I settled on using the Applescript with a launch agent, that worked, I just know shell a bit better. Thx for your help!
Posted on 05-14-2014 09:38 AM
Ha..."dict's in plists"...I'm still recovering from "flushing logs"... :P
Posted on 05-16-2014 07:54 PM
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 />
Posted on 10-23-2014 07:35 AM
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?
Posted on 10-25-2014 02:17 PM
Posted on 02-03-2015 06:44 AM
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)
Posted on 02-03-2015 07:55 AM
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).
Posted on 02-03-2015 11:32 AM
@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.
Posted on 02-04-2015 01:06 AM
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)
Posted on 08-19-2015 09:27 AM
can any of this be done with config profiles now?