Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
function! SelectaCommand(choice_command, vim_command)
try
silent! exec a:vim_command . " " . system(a:choice_command . " | selecta")
catch /Vim:Interrupt/
endtry
redraw!
endfunction
let g:selecta_command = 'find * ' .
\ '-type f ' .
\ '-not -wholename "*node_modules*" ' .
\ '-not -wholename "*vendor*" ' .
\ '-not -wholename "*tmp*" '
nmap <C-p> :call SelectaCommand(g:selecta_command, ":e")<CR>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment