navigation-file: use fdfind
This commit is contained in:
parent
29c896f017
commit
89dcb057cc
@ -12,7 +12,16 @@ function Fuzzy.open()
|
||||
Fuzzy.active = true
|
||||
|
||||
-- Collect all files once (cached for speed)
|
||||
Fuzzy.files = vim.fn.globpath('.', '**/*', 0, 1)
|
||||
-- Fuzzy.files = vim.fn.globpath('.', '**/*', 0, 1)
|
||||
|
||||
local handle = io.popen('fdfind --type f --hidden --exclude .git')
|
||||
if handle then
|
||||
local result = handle:read('*a')
|
||||
handle:close()
|
||||
Fuzzy.files = vim.split(result, '\n', { trimempty = true })
|
||||
else
|
||||
Fuzzy.files = {}
|
||||
end
|
||||
Fuzzy.matches = Fuzzy.files
|
||||
Fuzzy.cursor = 1
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user