From c049aadcd4ff216f0d354a03d8d438c6c6f29ed0 Mon Sep 17 00:00:00 2001 From: SamPosh Date: Thu, 13 Apr 2023 14:39:37 +0530 Subject: [PATCH] Hide .git and .github folders --- lua/custom/plugins/filetree.lua | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/lua/custom/plugins/filetree.lua b/lua/custom/plugins/filetree.lua index 96fbd152..318a8a9d 100644 --- a/lua/custom/plugins/filetree.lua +++ b/lua/custom/plugins/filetree.lua @@ -1,3 +1,5 @@ + + -- Unless you are still migrating, remove the deprecated commands from v1.x vim.cmd([[ let g:neo_tree_remove_legacy_commands = 1 ]]) @@ -10,7 +12,24 @@ return { "MunifTanjim/nui.nvim", }, config = function () - require('neo-tree').setup{} + require('neo-tree').setup{ + filesystem = { + filtered_items = { + visible = true, -- when true, they will just be displayed differently than normal items + hide_dotfiles = true, + hide_hidden = true, + hide_gitignored = true, + always_show = { -- remains visible even if other settings would normally hide it + ".vscode", + ".jenkinsfiles" + }, + never_show = { + ".git", + ".github" + } + } + } + } end, vim.keymap.set('n', '', 'Neotree toggle') }