git-worktree.nvim
git-worktree.nvim copied to clipboard
bug? nvim quits on_tree_change when the nvim-tree plugin is installed
I was trying the nvim-tree plugin which is a nerdTree-like but 100% lua. I know you are a netrw user but some of us mere mortals like the fuzz and whistles of those file browsers. Also given that you're THE Primeagem coconut oil supreme vim master, this is most likely a nvim-tree bug, of course. But I though I'd let you know anyway. For now I've fixed the problem by uninstalling nvim-tree. ;-) Thanks for this great plugin!
Can reproduce, switch_tree didn’t work when nvim-tree was enabled, I disabled nvim-tree and it started working,
update_focused_file = {
enable = true,
update_cwd = true
},
in nvim-tree.setup() seems to be the problem, i switched it to
update_focused_file = {
enable = false,
update_cwd = true
},
and switch_tree started working
Thanks @Ceres445 . I confirm the config workaround seems good.
Same for me, you don't want to have auto_close enabled, too. (it does what it's supposed to do)
require'nvim-tree'.setup {
auto_close = true
...
I also have this problem, update_focused_fiel is very useful function in nvim-tree though, so this workaround would not work for me
I have the following config but still seem to get weird issues with the file explorer not updating the path when switching trees. Anyone that have a working solution that could share theirs?
vim.opt.splitright = true
require'nvim-tree'.setup {
update_focused_file = {
enable = false,
update_cwd = true
},
}
Edit: The best solution I found was to also add the following so neovim opens netrw by default and when in folders I can still open nvim-tree. The only issue is that just opening nvim-tree will open the initial worktree but using the "open file in explorer" will open the correct worktree.
disable_netrw = false,
hijack_netrw = false,