Skip to content

Instantly share code, notes, and snippets.

@tristancollins
Created August 3, 2014 08:20
Show Gist options
  • Save tristancollins/6d8ef8d1c186605db43c to your computer and use it in GitHub Desktop.
Save tristancollins/6d8ef8d1c186605db43c to your computer and use it in GitHub Desktop.
A short script that opens mutt in a new terminal window at a set position and size
tell application "System Events"
if "Terminal" is not in name of processes then launch application "Terminal"
tell process "Terminal"
set frontmost to true
if (count windows) is greater than 0 then keystroke "n" using command down
if (count windows) is 0 then keystroke "n" using command down
end tell
end tell
tell application "Terminal" to tell window 1
set position to {0, 20}
set size to {600, 650}
delay 0.5
do script "mutt" in it
end tell
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment