Skip to content

Instantly share code, notes, and snippets.

@mdp
Created September 11, 2009 18:21
Show Gist options
  • Save mdp/185471 to your computer and use it in GitHub Desktop.
Save mdp/185471 to your computer and use it in GitHub Desktop.
on run argv
tell application "System Events" to tell process "Terminal" to keystroke "t" using command down -- open a new tab
tell application "Terminal" to do script "cd " & item 1 of argv in front window -- change directory
end run
-- in your profile
-- alias newtab='osascript ~/.applescripts/newtab.applescript `pwd`'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment