adaptación del script de http://thepugautomatic.com/2015/02/open-in-iterm-vim-from-finder/ para abrir ficheros en vim + iterm2 desde el Finder o abrir una vim + iterm2 en blanco
on run {input, parameters}
if input is equal to {} then
set cmd to "clear;cd `/Users/jasamitier`;vim "
else
set filename to POSIX path of input
set cmd to "clear;cd `dirname " & filename & "`;vim " & filename
end if
tell application "iTerm"
tell the current window
create window with default profile
tell the current session
write text cmd
end tell
end tell
end tell
end run