Predefined command option for VimuxPromptCommand

Added the possibility to specify a predefined command which
can be edited or completed in the prompt line.
fix-tmux-next-3dot4
Matthias Bilger 10 years ago
parent 1c3ca9e267
commit d78cd0f8e1

@ -11,7 +11,7 @@ command VimuxInspectRunner :call VimuxInspectRunner()
command VimuxScrollUpInspect :call VimuxScrollUpInspect()
command VimuxScrollDownInspect :call VimuxScrollDownInspect()
command VimuxInterruptRunner :call VimuxInterruptRunner()
command VimuxPromptCommand :call VimuxPromptCommand()
command -nargs=? VimuxPromptCommand :call VimuxPromptCommand(<args>)
command VimuxClearRunnerHistory :call VimuxClearRunnerHistory()
command VimuxTogglePane :call VimuxTogglePane()
@ -37,6 +37,7 @@ function! VimuxRunCommand(command, ...)
let g:VimuxLastCommand = a:command
call VimuxSendKeys(resetSequence)
echo a:command
call VimuxSendText(a:command)
if l:autoreturn == 1
@ -131,8 +132,8 @@ function! VimuxClearRunnerHistory()
endif
endfunction
function! VimuxPromptCommand()
let l:command = input(_VimuxOption("g:VimuxPromptString", "Command? "))
function! VimuxPromptCommand(command, ...)
let l:command = input(_VimuxOption("g:VimuxPromptString", "Command? "),a:command)
call VimuxRunCommand(l:command)
endfunction

Loading…
Cancel
Save