mirror of
https://github.com/junegunn/fzf
synced 2024-11-16 12:12:48 +00:00
[vim] Apply FZF_DEFAULT_{OPTS,COMMAND} when using tmux splits (#87)
This commit is contained in:
parent
a54784cd53
commit
cc9938d4c9
@ -149,10 +149,15 @@ function! s:execute(dict, command, temps)
|
|||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! s:execute_tmux(dict, command, temps)
|
function! s:execute_tmux(dict, command, temps)
|
||||||
if has_key(a:dict, 'dir')
|
|
||||||
let command = 'cd '.s:escape(a:dict.dir).' && '.a:command
|
|
||||||
else
|
|
||||||
let command = a:command
|
let command = a:command
|
||||||
|
if exists('$FZF_DEFAULT_OPTS')
|
||||||
|
let command = expand('FZF_DEFAULT_OPTS="$FZF_DEFAULT_OPTS" ') . command
|
||||||
|
endif
|
||||||
|
if exists('$FZF_DEFAULT_COMMAND')
|
||||||
|
let command = expand('FZF_DEFAULT_COMMAND="$FZF_DEFAULT_COMMAND" ') . command
|
||||||
|
endif
|
||||||
|
if has_key(a:dict, 'dir')
|
||||||
|
let command = 'cd '.s:escape(a:dict.dir).' && '.command
|
||||||
endif
|
endif
|
||||||
|
|
||||||
let splitopt = '-v'
|
let splitopt = '-v'
|
||||||
|
Loading…
Reference in New Issue
Block a user