Merge pull request #1107 from kyazdani42/#1099-search-obey-ignored

#1099 search obeys active ignore filters
This commit is contained in:
Alexander Courtis
2022-03-27 13:48:02 +11:00
committed by GitHub

View File

@@ -2,6 +2,7 @@ local api = vim.api
local uv = vim.loop
local utils = require "nvim-tree.utils"
local core = require "nvim-tree.core"
local filters = require "nvim-tree.explorer.filters"
local find_file = require("nvim-tree.actions.find-file").fn
local M = {}
@@ -27,6 +28,7 @@ local function search(dir, input_path)
break
end
if not filters.should_ignore(path) then
if string.find(path, "/" .. input_path .. "$") then
return path
end
@@ -37,6 +39,7 @@ local function search(dir, input_path)
return path
end
end
end
name, _ = uv.fs_scandir_next(handle)
end