Created
August 8, 2014 00:23
-
-
Save e0da/f7d0a083c6a38d16cb36 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
function kill_Terminal() { | |
osascript -e " | |
try -- I don't care if everything fails | |
try -- So we can ignore when the timeout fails | |
with timeout of 0.1 seconds -- So we don't block on the modal | |
tell application \"Terminal\" to quit | |
end timeout | |
end try | |
tell application \"System Events\" to click UI element \"Close\" of sheet 1 of window 1 of application process \"Terminal\" | |
end try | |
" | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment