neotree follow

This commit is contained in:
Your Name 2026-07-17 15:40:01 +08:00
parent 5dc5b06933
commit 8ed02b751e
1 changed files with 4 additions and 0 deletions

View File

@ -11,6 +11,10 @@ vim.keymap.set('n', '\\', '<Cmd>Neotree reveal<CR>', { desc = 'NeoTree reveal',
require('neo-tree').setup {
filesystem = {
follow_current_file = {
enabled = true, -- This finds and focuses the file in the active buffer every time a new file is opened
leave_dirs_open = false, -- Closes folders when you leave them (set to true if you prefer keeping them open)
},
window = {
mappings = {
['\\'] = 'close_window',