The purpose of this script is to assign Lync policies to Lync-enabled users, based on their Active Directory group membership.
 This will apply only to user-scope policies.

The script is capable of assiging the following:

1     Voice Policy
2     Client Policy
 3     External Access Policy
 4     Mobility Policy
 5     Archiving Policy
 6     Hosted Voicemail Policy
 7     Client Version Policy
 8     Conferencing Policy
 9     Voice Routing Policy
 10     Location Policy
 11     PIN Policy
 12     Presence Policy
 13     Persistent Chat Policy
 14     Dial Plans

The script will automatically elevate your Local admin persmissions if required.

Detailed information can be found in my blog: