Remove ZoomRunnerPane in favor of FocusRunnerPane
The functionality was largely duplicated across the commands, and with regard to naming, `FocusRunnerPane` better maps to how I use it. Closes #35 - Unify Focus & Zoom runner pane functions
This commit is contained in:
parent
e1749bc7fb
commit
e8abf1ae69
@ -21,7 +21,6 @@ CONTENTS *vtr-contents*
|
|||||||
2.11 ............................... |VtrClearRunner|
|
2.11 ............................... |VtrClearRunner|
|
||||||
2.12 ............................... |VtrFlushCommand|
|
2.12 ............................... |VtrFlushCommand|
|
||||||
2.13 ............................... |VtrSendCtrlD|
|
2.13 ............................... |VtrSendCtrlD|
|
||||||
2.14 ............................... |VtrZoomRunnerPane|
|
|
||||||
3. Configuration ................... |VTR-Configuration|
|
3. Configuration ................... |VTR-Configuration|
|
||||||
3.1 ................................ |VtrPercentage|
|
3.1 ................................ |VtrPercentage|
|
||||||
3.2 ................................ |VtrOrientation|
|
3.2 ................................ |VtrOrientation|
|
||||||
@ -218,20 +217,6 @@ Send Ctrl-D key sequence to the runner without resetting the current command.
|
|||||||
This is useful if you are repeatedly running a script in the debugger and
|
This is useful if you are repeatedly running a script in the debugger and
|
||||||
regularly need to kill the repl.
|
regularly need to kill the repl.
|
||||||
|
|
||||||
------------------------------------------------------------------------------
|
|
||||||
*VtrZoomRunnerPane*
|
|
||||||
2.12 VtrZoomRunnerPane~
|
|
||||||
|
|
||||||
Zoom the runner pane using the native zooming functionality from tmux 1.8.
|
|
||||||
This will cause the runner pane to temporarily occupy the entire tmux window.
|
|
||||||
This is useful for temporarily viewing the pane in a larger context, ie to see
|
|
||||||
a long bracktrace.
|
|
||||||
|
|
||||||
You can add the following mapping to your ~/.tmux.conf file to enable quick
|
|
||||||
toggling of the zoom functionality:
|
|
||||||
|
|
||||||
bind C-p run "(tmux display-message -p '#{pane_current_command}' | grep -iqE '(^|\/)vim$' && tmux send-keys ':VtrZoomRunnerPane' 'C-m') || tmux select-pane -l"
|
|
||||||
|
|
||||||
==============================================================================
|
==============================================================================
|
||||||
CONFIGURATION (3) *VTR-Configuration*
|
CONFIGURATION (3) *VTR-Configuration*
|
||||||
|
|
||||||
|
@ -121,14 +121,6 @@ function! s:FocusRunnerPane()
|
|||||||
call s:SendTmuxCommand("resize-pane -Z")
|
call s:SendTmuxCommand("resize-pane -Z")
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! s:ZoomRunnerPane()
|
|
||||||
if !s:RequireRunnerPane() | return | endif
|
|
||||||
let copy_mode_cmd = s:TargetedTmuxCommand("copy-mode", s:runner_pane)
|
|
||||||
let zoom_command = s:TargetedTmuxCommand("resize-pane -Z", s:runner_pane)
|
|
||||||
call s:SendTmuxCommand(copy_mode_cmd)
|
|
||||||
call s:SendTmuxCommand(zoom_command)
|
|
||||||
endfunction
|
|
||||||
|
|
||||||
function! s:Strip(string)
|
function! s:Strip(string)
|
||||||
return substitute(a:string, '^\s*\(.\{-}\)\s*\n\?$', '\1', '')
|
return substitute(a:string, '^\s*\(.\{-}\)\s*\n\?$', '\1', '')
|
||||||
endfunction
|
endfunction
|
||||||
@ -391,7 +383,6 @@ function! s:DefineCommands()
|
|||||||
command! VtrFlushCommand call s:FlushCommand()
|
command! VtrFlushCommand call s:FlushCommand()
|
||||||
command! VtrSendCtrlD call s:SendCtrlD()
|
command! VtrSendCtrlD call s:SendCtrlD()
|
||||||
command! VtrAttachToPane call s:PromptForRunnerToAttach()
|
command! VtrAttachToPane call s:PromptForRunnerToAttach()
|
||||||
command! VtrZoomRunnerPane call s:ZoomRunnerPane()
|
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! s:DefineKeymaps()
|
function! s:DefineKeymaps()
|
||||||
@ -407,7 +398,6 @@ function! s:DefineKeymaps()
|
|||||||
nnoremap <leader>dr :VtrDetachRunner<cr>
|
nnoremap <leader>dr :VtrDetachRunner<cr>
|
||||||
nnoremap <leader>cr :VtrClearRunner<cr>
|
nnoremap <leader>cr :VtrClearRunner<cr>
|
||||||
nnoremap <leader>fc :VtrFlushCommand<cr>
|
nnoremap <leader>fc :VtrFlushCommand<cr>
|
||||||
nnoremap <leader>zr :VtrZoomRunnerPane<cr>
|
|
||||||
endif
|
endif
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user