Merge pull request #190 from jaspertandy/master

fix-tmux-next-3dot4
Caleb Maclennan 3 years ago committed by GitHub
commit 708ce200d5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -431,5 +431,21 @@ Caution: It is probably best not to mix this with |VimuxRunnerName|.
<
Default: 0
------------------------------------------------------------------------------
*VimuxCommandShell*
4.12 g:VimuxCommandShell~
Set this option to `1` or `v:true` to enable shell completion in
VimuxPromptCommand
Set this option to `0` or `v:false` to enable vim command editing in
VimuxPromptCommand
Enabling shell completion blocks the ability to use up-arrow to cycle through
previously-run commands in VimuxPromptCommand.
>
let g:VimuxCommandShell = 0
<
Default: 1
==============================================================================
vim:tw=78:ts=2:sw=2:expandtab:ft=help:norl:

@ -16,6 +16,7 @@ let g:VimuxTmuxCommand = get(g:, 'VimuxTmuxCommand', 'tmux')
let g:VimuxUseNearest = get(g:, 'VimuxUseNearest', v:true)
let g:VimuxExpandCommand = get(g:, 'VimuxExpandCommand', v:false)
let g:VimuxCloseOnExit = get(g:, 'VimuxCloseOnExit', v:false)
let g:VimuxCommandShell = get(g:, 'VimuxCommandShell', v:true)
function! VimuxOption(name) abort
return get(b:, a:name, get(g:, a:name))
@ -175,7 +176,11 @@ endfunction
function! VimuxPromptCommand(...)
let command = a:0 ==# 1 ? a:1 : ''
let l:command = input(VimuxOption('VimuxPromptString'), command, 'shellcmd')
if VimuxOption('VimuxCommandShell')
let l:command = input(VimuxOption('VimuxPromptString'), command, 'shellcmd')
else
let l:command = input(VimuxOption('VimuxPromptString'), command)
endif
if VimuxOption('VimuxExpandCommand')
let l:command = join(map(split(l:command, ' '), 'expand(v:val)'), ' ')
endif

Loading…
Cancel
Save