Closed
Description
Description
I have the following line
filters = {
dotfiles = true,
exclude = { ".config", ".local" },
},
And now gitignore files are always shown, and using I
to toggle them doesn't work.
If I remove the line with exclude
, all works fine.
Neovim version
NVIM v0.6.1
Build type: Release
LuaJIT 2.1.0-beta3
Compiled by builduser
Operating system and version
Arch Linux , kernel - 5.17.1-arch1-1
nvim-tree version
commit 618ea25
Steps to reproduce
- Create a folder with .gitignore and a couple of files
- Gitignore
file1
nvim -nu /tmp/nvt-min.lua
:NvimTreeToggle
- Observe the gitignored file being show
- Press
I
- gitignored file still shown
Expected behavior
- Gitignored files are not shown by default
- Gitignored files are toggled with
I
Actual behavior
No response
Minimal config
vim.cmd([[set runtimepath=$VIMRUNTIME]])
vim.cmd([[set packpath=/tmp/nvt-min/site]])
local package_root = "/tmp/nvt-min/site/pack"
local install_path = package_root .. "/packer/start/packer.nvim"
local function load_plugins()
require("packer").startup({
{
"wbthomason/packer.nvim",
"kyazdani42/nvim-tree.lua",
"kyazdani42/nvim-web-devicons",
},
config = {
package_root = package_root,
compile_path = install_path .. "/plugin/packer_compiled.lua",
display = { non_interactive = true },
},
})
end
if vim.fn.isdirectory(install_path) == 0 then
print("Installing nvim-tree and dependencies.")
vim.fn.system({ "git", "clone", "--depth=1", "https://github.com/wbthomason/packer.nvim", install_path })
end
load_plugins()
require("packer").sync()
vim.cmd([[autocmd User PackerComplete ++once echo "Ready!" | lua setup()]])
vim.opt.termguicolors = true
vim.opt.cursorline = true
-- MODIFY NVIM-TREE SETTINGS THAT ARE _NECESSARY_ FOR REPRODUCING THE ISSUE
_G.setup = function()
require("nvim-tree").setup({
filters = {
dotfiles = true,
exclude = { ".config", ".local" },
},
})
end