Skip to content

Instantly share code, notes, and snippets.

@chemzqm
Last active December 26, 2015 11:41
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save chemzqm/83a033de1114df0c3e02 to your computer and use it in GitHub Desktop.
Save chemzqm/83a033de1114df0c3e02 to your computer and use it in GitHub Desktop.
some osascript
#!/bin/sh
osascript <<END
tell application "MacVim"
activate
end tell
END
tell application "iTerm"
tell current window
set oldtab to the current tab
set newTab to (create tab with default profile)
tell current session
set title to "ls"
set name to "ls"
write text "mocha /Users/chemzqm/nodejs-dev/parsefunc/test"
end tell
tell current tab
close
end tell
select oldtab
end tell
end tell
function prompt_user
echo '<----- press any key to continue ----->'
read -p '' -n 1 foo
exit
end
~
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment