I am using fzf.vim, I have set FZF_DEFAULT_COMMAND='fd'
to improve search speed.
But 'fd' default behavior will respect .gitignore, .ignore files, and filter hidden files. It's useful in most cases, but not all.
So I want to create another command FilesUnrestrict
, still using 'fd', but with two options: '--no-ignore --hidden', so all files will be find.
Here is my command:
command! -bang -nargs=? FilesUnrestrict
\ call fzf#vim#grep('fd -tf -tl -i -u --exclude ".git" '.shellescape(<q-args>), 0, fzf#vim#with_preview(), <bang>0)
It is good to open fd and fuzzy search the files, but when type Enter to open the file, there is an error:
Here is the related issue:https://github.com/junegunn/fzf.vim/issues/1454
How could I solve this issue?