Created
November 24, 2021 20:40
-
-
Save macmule/5df4fbf8f0c4179498fad8344a3597f9 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ---- Map Printers | |
| if ADGroups contains "GROUPNAME" then | |
| if installedPrinters does not contain "PRINTERNAME" then | |
| try | |
| do shell script "/usr/sbin/lpadmin -p PRINTERNAME -E -v lpd://PRINTERIP -P PPDLOCATION -L \"PRINTERLOCATION\" -o printer-is-shared=false" | |
| on error | |
| do shell script "/usr/sbin/lpadmin -p PRINTERNAME -E -v lpd://PRINTERIP -P /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/PrintCore.framework/Versions/A/Resources/Generic.ppd -L \"PRINTERLOCATION\" -o printer-is-shared=false" | |
| end try | |
| end if | |
| end if |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment