Last active
January 7, 2022 13:50
-
-
Save chris1111/c44046e7a4aef9905fc1e697b46a7fd2 to your computer and use it in GitHub Desktop.
This file contains 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
# Eject Disk image or External Disk Applescript | |
# Applescript from chris1111 2020. | |
# (I think is the only Applescript that does not crash if the disk that has to unmount does not exist) | |
# Change the name MYDISK to the name you want | |
tell application "Finder" | |
activate | |
if exists disk "MYDISK" then | |
tell application "Finder" to eject disk "MYDISK" | |
end if | |
end tell |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment