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
| use framework "Foundation" | |
| set fileManager to current application's NSFileManager's defaultManager() | |
| set volname to (fileManager's displayNameAtPath:"/") as text |
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
| if ADGroups contains "<insert_printer_name>" then | |
| if installedPrinters does not contain "<insert_printer_name>" then | |
| try | |
| do shell script "/usr/sbin/lpadmin -p <insert_printer_name> -E -v lpd://<insert_printer_name>.macmule.com -P /Library/Printers/PPDs/Contents/Resources/en.lproj/Canon\\ iR-ADV\\ C5200s-B2\\ PS\\ V1.0 -o printer-is-shared=false -o EFDuplex=False" | |
| on error | |
| do shell script "/usr/sbin/lpadmin -p <insert_printer_name> -E -v lpd://<insert_printer_name>.macmule.com -P /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/PrintCore.framework/Versions/A/Resources/Generic.ppd -o printer-is-shared=false" | |
| end try | |
| end if | |
| end if |
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
| diskutil coreStorage | |
| Usage: diskutil [quiet] coreStorage|CS <verb> <options>, | |
| where <verb> is as follows: | |
| list (Show status of CoreStorage volumes) | |
| info[rmation] (Get CoreStorage information by UUID or disk) | |
| convert (Convert a volume into a CoreStorage volume) | |
| revert (Revert a CoreStorage volume to its native type) | |
| create (Create a new CoreStorage logical volume group) | |
| delete (Delete a CoreStorage logical volume group) |
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
| #!/bin/sh | |
| # Echo target drive | |
| echo "Target drive is: $1" | |
| # Delete the CoreStorage volume | |
| /usr/sbin/diskutil coreStorage deleteVolume "$1" | |
| echo "CoreStorage volume $1 deleted" | |
| # Get the UUID of the CoreStorage Logical Volume Group |
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
| #!/bin/sh | |
| # Get the UUID of the CoreStorage Logical Volume Group | |
| csLVGUUID=`/usr/sbin/diskutil corestorage list | awk '/Logical Volume Group/{print $NF}'` | |
| echo "We are going to delete the Logical Volume Group with UUID: $csLVGUUID..." | |
| # Delete the CoreStorage Volume | |
| /usr/sbin/diskutil corestorage delete "$csLVGUUID" | |
| echo "Deleted the Logical Volume Group $csLVGUUID..." |
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
| <?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>Label</key> | |
| <string>com.macmule.corestoragerevert</string> | |
| <key>Program</key> | |
| <string>/Applications/CoreStorage Revert.app/Contents/MacOS/applet</string> | |
| <key>RunAtLoad</key> | |
| <true/> |
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
| #!/bin/sh | |
| ## postinstall | |
| targetVolume=$3 | |
| ## Delete the AutoCasperNBI installed Casper Imaging launch agent | |
| rm -rf "$3"/Library/LaunchAgents/com.AutoCasperNBI.CasperImaging.plist | |
| ## If the launch agent exists after the above, error | |
| if [ -f "$3"/Library/LaunchAgents/com.AutoCasperNBI.CasperImaging.plist ]; |
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
| -- Get the name Volume Name of the Macs CoreStorage volume. | |
| set csVolume to do shell script "diskutil cs list | awk '/Volume Name:/{out=$3; for(i=4;i<=NF;i++){out=out\" \"$i}; print out}'" | |
| -- If the above command come back with a Volume Name. | |
| if csVolume is not "" then | |
| -- Set this app to the front | |
| tell application "System Events" to set frontmost of process "CoreStorage Revert" to true | |
| -- Advise that volume needs to be reverted, offering option to skip if wanted |
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
| #!/bin/bash | |
| #################################################################################################### | |
| # | |
| # License: https://macmule.com/license/ | |
| # | |
| ################################################################################################### | |
| # | |
| # DEFINE VARIABLES & READ IN PARAMETERS | |
| # | |
| #################################################################################################### |
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
| #!/bin/sh | |
| #################################################################################################### | |
| # | |
| # License: https://macmule.com/license/ | |
| # | |
| #################################################################################################### | |
| ### | |
| # Get the Active Directory Node Name | |
| ### |