(* Freeware AppleScript from WhatsMyIP.org © 2017 Check out our other scripts! @ http://www.whatsmyip.org/lib/applescripts/ Image Folder makes a disk image out of a folder. You can drag a folder on to this script or double-click the script. *) on run set x to choose folder with prompt "Please choose a folder to Image..." open x end run on open x if folder of (info for x) then set PathToFolder to do shell script "dirname '" & (POSIX path of x) & "'" set NameOfFolder to name of (info for x) do shell script "hdiutil create '" & PathToFolder & "/" & NameOfFolder & ".dmg' -srcfolder '" & (POSIX path of x) & "' -format UDZO" display dialog "Disk Image '" & NameOfFolder & ".dmg' has been created." buttons "OK" default button 1 with icon note else display dialog "This scripts makes disk images from folders. Please drop a folder on this scripts" buttons "OK" default button 1 with icon stop end if end open