Add zoom runner command and map
This commit is contained in:
parent
191d9d843c
commit
cf0b282fe2
@ -26,7 +26,7 @@ VTR, check [the included doc file][].
|
|||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
The easiest way to install VTR is to add the git repo as a bundle, then use
|
The easiest way to install VTR is to add the git repo as a bundle, then use
|
||||||
[Pathogen][], [Vundle][] or similar plugin management option to add it to Vim's
|
[Pathogen][], [Vundle][] or similar plugin management option to add it to Vim's
|
||||||
runtime path.
|
runtime path.
|
||||||
|
|
||||||
|
@ -21,6 +21,7 @@ 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|
|
||||||
@ -217,6 +218,15 @@ 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.
|
||||||
|
|
||||||
==============================================================================
|
==============================================================================
|
||||||
CONFIGURATION (3) *VTR-Configuration*
|
CONFIGURATION (3) *VTR-Configuration*
|
||||||
|
|
||||||
|
@ -127,6 +127,12 @@ function! s:FocusRunnerPane()
|
|||||||
call s:FocusTmuxPane(s:runner_pane)
|
call s:FocusTmuxPane(s:runner_pane)
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
|
function! s:ZoomRunnerPane()
|
||||||
|
call s:EnsureRunnerPane()
|
||||||
|
let targeted_cmd = s:TargetedTmuxCommand("resize-pane -Z", s:runner_pane)
|
||||||
|
call s:SendTmuxCommand(targeted_cmd)
|
||||||
|
endfunction
|
||||||
|
|
||||||
function! s:SendTmuxCommand(command)
|
function! s:SendTmuxCommand(command)
|
||||||
let prefixed_command = "tmux " . a:command
|
let prefixed_command = "tmux " . a:command
|
||||||
return system(prefixed_command)
|
return system(prefixed_command)
|
||||||
@ -389,6 +395,7 @@ 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:AttachToPane()
|
command! VtrAttachToPane call s:AttachToPane()
|
||||||
|
command! VtrZoomRunnerPane call s:ZoomRunnerPane()
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! s:DefineKeymaps()
|
function! s:DefineKeymaps()
|
||||||
@ -402,9 +409,9 @@ function! s:DefineKeymaps()
|
|||||||
nmap ,kr :VtrKillRunner<cr>
|
nmap ,kr :VtrKillRunner<cr>
|
||||||
nmap ,fr :VtrFocusRunner<cr>
|
nmap ,fr :VtrFocusRunner<cr>
|
||||||
nmap ,dr :VtrDetachRunner<cr>
|
nmap ,dr :VtrDetachRunner<cr>
|
||||||
nmap ,ar :VtrReattachRunner<cr>
|
|
||||||
nmap ,cr :VtrClearRunner<cr>
|
nmap ,cr :VtrClearRunner<cr>
|
||||||
nmap ,fc :VtrFlushCommand<cr>
|
nmap ,fc :VtrFlushCommand<cr>
|
||||||
|
nmap ,zr :VtrZoomRunnerPane<cr>
|
||||||
endif
|
endif
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user