fix : update nvimtree config

This commit is contained in:
siduck76 2021-09-25 22:11:27 +05:30
parent e408a1168f
commit 2685ad8e30

View file

@ -12,23 +12,15 @@ vim.o.termguicolors = true
g.nvim_tree_add_trailing = 0 -- append a trailing slash to folder names
g.nvim_tree_allow_resize = 1
g.nvim_tree_auto_close = 0 -- closes tree when it's the last window
g.nvim_tree_auto_ignore_ft = { "dashboard" } -- don't open tree on specific fiypes.
g.nvim_tree_auto_open = 0
g.nvim_tree_disable_netrw = 1
g.nvim_tree_follow = 1
g.nvim_tree_git_hl = git_status
g.nvim_tree_gitignore = git_status
g.nvim_tree_hide_dotfiles = 0
g.nvim_tree_highlight_opened_files = 0
g.nvim_tree_hijack_netrw = 0
g.nvim_tree_indent_markers = 1
g.nvim_tree_ignore = { ".git", "node_modules", ".cache" }
g.nvim_tree_quit_on_open = 0 -- closes tree when file's opened
g.nvim_tree_root_folder_modifier = table.concat { ":t:gs?$?/..", string.rep(" ", 1000), "?:gs?^??" }
g.nvim_tree_side = "left"
g.nvim_tree_tab_open = 0
g.nvim_tree_update_cwd = 1
g.nvim_tree_width = 25
g.nvim_tree_lsp_diagnostics = 0
@ -97,3 +89,17 @@ g.nvim_tree_bindings = {
{ key = "q", cb = tree_cb "close" },
{ key = "g?", cb = tree_cb "toggle_help" },
}
require("nvim-tree").setup {
disable_netrw = true,
hijack_netrw = true,
ignore_ft_on_setup = { "dashboard" },
auto_close = false,
open_on_tab = false,
hijack_cursor = true,
update_cwd = true,
update_focused_file = {
enable = true,
update_cwd = true,
},
}