AppleScripts Stopped Working
The following AppleScripts, stopped working. This occurs when I attempt to run the script from within the Script Editor, and, when I run the script from applications that I saved them as.
Recently, I erased the internal hard drive, on my iMac. I reinstalled OS X El Capitan, the applications, and my user data. Subsequently, the AppleScripts stopped working. The AppleScript code, follows:
Reboot To Selected Volumes:
display dialog "Select a startup disk" buttons ¬
{"Macintosh HD", "Macintosh HD Maintenance Clone", "iMac Bootable Clone FD - KRT"}
set bootVol to the button returned of the result as text
do shell script "bless -mount \"/Volumes/" & bootVol & ¬
"\" -setBoot" with administrator privileges
do shell script "shutdown -r now" with administrator privileges
Reboot To Macintosh HD:
set deviceID to (do shell script "diskutil list | awk '/Macintosh HD/ {print $NF}'")
do shell script "bless -device /dev/" & deviceID & ¬
" -setBoot -nextonly" with administrator privileges
tell application "Finder" to restart
Reboot To Macintosh HD Maintenance Clone:
set deviceID to (do shell script "diskutil list | awk '/Macintosh HD Maintenance Clone/ {print $NF}'")
do shell script "bless -device /dev/" & deviceID & ¬
" -setBoot -nextonly" with administrator privileges
tell application "Finder" to restart
Any thoughts?
Thank you.
iMac, OS X El Capitan (10.11.3)