Skip to content

Instantly share code, notes, and snippets.

@maxjustus
Forked from brycemcd/.vimrc
Created September 28, 2012 17:04
Show Gist options
  • Save maxjustus/3801002 to your computer and use it in GitHub Desktop.
Save maxjustus/3801002 to your computer and use it in GitHub Desktop.
tmux and vim integration
command! -nargs=1 Silent
\ | execute ':silent !'.<q-args>
\ | execute ':redraw!'
" test the current file in the next tmux window
nmap <leader>tt :Silent tmux send-keys -t 1 "rspec %" C-m <cr>
" test the line from user input
nmap <leader>tl :Silent tmux send-keys -t 1 "rspec %:<C-r>=line('.')<cr>" C-m <cr>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment