Skip to content

Commit

Permalink
feat: speed up directory traversal with fd (list command)
Browse files Browse the repository at this point in the history
This typically prevents going into the `.git` directory when matching on
`.git`, thus making traversal faster.
  • Loading branch information
cljoly committed Aug 2, 2024
1 parent a2f0367 commit 58f9363
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lua/telescope/_extensions/repo/list.lua
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ M.prepare_command = function(opts)

-- Don’t filter only on directories with fd as git worktrees actually have a
-- .git file in them.
local find_repo_opts = { "--hidden", "--no-ignore-vcs", "--case-sensitive", "--absolute-path" }
local find_repo_opts = { "--prune", "--hidden", "--no-ignore-vcs", "--case-sensitive", "--absolute-path" }
local find_user_opts = opts.fd_opts or {}
local find_exec_opts = opts.fd_exec_opts or (function()
if vim.fn.has("win32") == 1 or vim.fn.has("win64") == 1 then
Expand Down

0 comments on commit 58f9363

Please sign in to comment.