diff --git a/doc/telescope-frecency.txt b/doc/telescope-frecency.txt index e4e4233..7d2e1bf 100644 --- a/doc/telescope-frecency.txt +++ b/doc/telescope-frecency.txt @@ -584,8 +584,8 @@ Type: `"LUA"|string[]|nil` With the default value: `nil`, it uses these ways below to make entries for workspace files. It tries in order until it works successfully. -1. `fdfind -Htf` -2. `fd -Htf` +1. `fdfind -Htf -E .git` +2. `fd -Htf -E .git` 3. `rg -.g '!.git' --files` 4. Native Lua code (old way) diff --git a/lua/frecency/finder.lua b/lua/frecency/finder.lua index 559c18c..bafd9af 100644 --- a/lua/frecency/finder.lua +++ b/lua/frecency/finder.lua @@ -83,7 +83,7 @@ function Finder:start(epoch) if config.workspace_scan_cmd ~= "LUA" and self.need_scan_dir then ---@type string[][] local cmds = config.workspace_scan_cmd and { config.workspace_scan_cmd } - or { { "fdfind", "-Htf" }, { "fd", "-Htf" }, { "rg", "-.g", "!.git", "--files" } } + or { { "fdfind", "-Htf", "-E", ".git" }, { "fd", "-Htf", "-E", ".git" }, { "rg", "-.g", "!.git", "--files" } } for _, c in ipairs(cmds) do ok = self:scan_dir_cmd(c) if ok then