We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
BufEnter
1 parent 74ddb8f commit 874ae6eCopy full SHA for 874ae6e
lua/nvim-tree.lua
@@ -283,8 +283,8 @@ local function setup_autocommands(opts)
283
create_nvim_tree_autocmd("BufEnter", {
284
pattern = "NvimTree_*",
285
callback = function()
286
- if opts.reload_on_bufenter and not opts.filesystem_watchers.enable then
287
- if utils.is_nvim_tree_buf(0) then
+ if utils.is_nvim_tree_buf(0) then
+ if vim.fn.getcwd() ~= core.get_cwd() or (opts.reload_on_bufenter and not opts.filesystem_watchers.enable) then
288
reloaders.reload_explorer()
289
end
290
0 commit comments