From 8213801b89e9d2a27c6b1df50881b8476679b870 Mon Sep 17 00:00:00 2001 From: Gustaf Rydholm Date: Thu, 2 Dec 2021 23:02:50 +0100 Subject: LunarVim updates --- .config/nvim/lua/core/nvimtree.lua | 46 ++++++++++++++++++++++++++++++-------- 1 file changed, 37 insertions(+), 9 deletions(-) (limited to '.config/nvim/lua/core/nvimtree.lua') diff --git a/.config/nvim/lua/core/nvimtree.lua b/.config/nvim/lua/core/nvimtree.lua index 2ca2fb1..b525351 100644 --- a/.config/nvim/lua/core/nvimtree.lua +++ b/.config/nvim/lua/core/nvimtree.lua @@ -6,12 +6,22 @@ function M.config() active = true, on_config_done = nil, setup = { + disable_netrw = true, + hijack_netrw = true, open_on_setup = false, - auto_close = true, - open_on_tab = false, - update_focused_file = { + ignore_ft_on_setup = { + "startify", + "dashboard", + "alpha", + }, + update_to_buf_dir = { enable = true, + auto_open = true, }, + auto_close = true, + open_on_tab = false, + hijack_cursor = false, + update_cwd = false, diagnostics = { enable = true, icons = { @@ -21,14 +31,36 @@ function M.config() error = "", }, }, + update_focused_file = { + enable = true, + update_cwd = true, + ignore_list = {}, + }, + system_open = { + cmd = nil, + args = {}, + }, + git = { + enable = true, + ignore = true, + timeout = 200, + }, view = { width = 30, + height = 30, side = "left", auto_resize = true, + number = false, + relativenumber = false, mappings = { custom_only = false, + list = {}, }, }, + filters = { + dotfiles = true, + custom = { ".git", "node_modules", ".cache" }, + }, }, show_icons = { git = 1, @@ -37,13 +69,10 @@ function M.config() folder_arrows = 1, tree_width = 30, }, - ignore = { ".git", "node_modules", ".cache" }, quit_on_open = 0, - hide_dotfiles = 0, git_hl = 1, + disable_window_picker = 0, root_folder_modifier = ":t", - allow_resize = 1, - auto_ignore_ft = { "startify", "dashboard" }, icons = { default = "", symlink = "", @@ -65,6 +94,7 @@ function M.config() }, }, } + options.builtin.which_key.mappings["e"] = { "NvimTreeToggle", "Explorer" } end function M.setup() @@ -98,8 +128,6 @@ function M.setup() } end - options.builtin.which_key.mappings["e"] = { "NvimTreeToggle", "Explorer" } - local tree_view = require "nvim-tree.view" -- Add nvim_tree open callback -- cgit v1.2.3-70-g09d2