Vim Tmux Runner

I think one of the best things I can do is get a healthy understanding to TMUX runner. It may be the most beneficial way to test and run code… just having a little trouble getting it all set up…

leader = SpaceBar

The first Step: Open the Pane that will run your commands

leader + or

The second Step: Send Lines to the runner

Let’s say you have a rails console open. And you’re working with a method and you want to test it… you can highlight the lines in vim, then hit leader + sl -> sl = send lines

Ok that will get your code into irb or the rails console.

Then… you can tell the Vtr to run a command.. leader + sc

When you’re done with that command, you can flush it from memory… leader + fc

All Available Commands

    nnoremap <leader>va :VtrAttachToPane<cr>
    nnoremap <leader>ror :VtrReorientRunner<cr>
    nnoremap <leader>sc :VtrSendCommandToRunner<cr>
    nnoremap <leader>sl :VtrSendLinesToRunner<cr>
    vnoremap <leader>sl :VtrSendLinesToRunner<cr>
    nnoremap <leader>or :VtrOpenRunner<cr>
    nnoremap <leader>kr :VtrKillRunner<cr>
    nnoremap <leader>fr :VtrFocusRunner<cr>
    nnoremap <leader>dr :VtrDetachRunner<cr>
    nnoremap <leader>cr :VtrClearRunner<cr>
    nnoremap <leader>fc :VtrFlushCommand<cr>
    nnoremap <leader>sf :VtrSendFile<cr>

Post Content