Skip to content

Instantly share code, notes, and snippets.

@lukaszkorecki
Created August 11, 2014 11:12
Show Gist options
  • Save lukaszkorecki/be73a1dafb6452f06b09 to your computer and use it in GitHub Desktop.
Save lukaszkorecki/be73a1dafb6452f06b09 to your computer and use it in GitHub Desktop.
function! RspecInPane()
exec "Gcd"
let f = expand("%")
let cmd = "tmux split-window \"bundle exec rspec " . shellescape(f) . ";sh\""
silent exec "! ".cmd
endf
map <leader>r :silent call RspecInPane()<cr>
function! AllRspecInPane()
exec "Gcd"
silent exec "! tmux split-window \"bundle exec rspec ;sh\""
endf
map <leader>R :silent call AllRspecInPane()<cr>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment