diff options
| author | jdhao <jdhao@hotmail.com> | 2022-02-05 13:42:53 +0800 |
|---|---|---|
| committer | jdhao <jdhao@hotmail.com> | 2022-02-05 13:42:53 +0800 |
| commit | f357b0bee8523e5f3a9a38465d223608041f3460 (patch) | |
| tree | 18fcacf3f3f21d76707cf3f5e2a3ad892280a0c4 /lua/config | |
| parent | 2b24d0794e95ce45e9bbd346c99a3bd76f127102 (diff) | |
nvim-tree: auto-close when it is the only win
Diffstat (limited to 'lua/config')
| -rw-r--r-- | lua/config/nvim-tree.lua | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lua/config/nvim-tree.lua b/lua/config/nvim-tree.lua index d694dc0..cbd303b 100644 --- a/lua/config/nvim-tree.lua +++ b/lua/config/nvim-tree.lua @@ -5,7 +5,7 @@ nvim_tree.setup({ hijack_netrw = true, open_on_setup = false, ignore_ft_on_setup = {}, - auto_close = false, + auto_close = true, open_on_tab = false, hijack_cursor = false, update_cwd = false, @@ -59,4 +59,5 @@ nvim_tree.setup({ require_confirm = true, }, }) + vim.api.nvim_set_keymap("n", "<space>s", "<cmd>NvimTreeToggle<CR>", { noremap = true, silent = true }) |
