Skip to content
Myr

[vim] Expose fzf#exec() function

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Junegunn Choi · committed by Junegunn Choi · parent 0db65c2 · Browse files · 1 file+4 added−4 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+4 added−4 removed

  • other:+4 added−4 removed

1 file+4 added−4 removed

modified:plugin/fzf.vim+4 added-4 removed
143 unmodified lines
144 throw 'Failed to download fzf: '.script145 endif146endfunction147148function! s:fzf_exec()148function! fzf#exec()149 if !exists('s:exec')150 if executable(s:fzf_go)151 let s:exec = s:fzf_go152 elseif executable('fzf')153 let s:exec = 'fzf'154 elseif input('fzf executable not found. Download binary? (y/n) ') =~? '^y'155 redraw156 call fzf#install()157 return s:fzf_exec()157 return fzf#exec()158 else159 redraw160 throw 'fzf executable not found'161 endif162 endif163 return fzf#shellescape(s:exec)163 return s:exec164endfunction165166function! s:tmux_enabled()167 if has('gui_running') || !exists('$TMUX')
207 unmodified lines
375 let dict = exists('a:1') ? copy(a:1) : {}376 let temps = { 'result': s:fzf_tempname() }377 let optstr = s:evaluate_opts(get(dict, 'options', ''))378 try379 let fzf_exec = s:fzf_exec()379 let fzf_exec = fzf#shellescape(fzf#exec())380 catch381 throw v:exception382 endtry383
572 unmodified lines