We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
sync_root_with_cwd = true
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
When I open a file and Neovim changes cwd, nvim-tree does not follow.
NVIM v0.9.0-dev-565+gd215dae0e0 Build type: RelWithDebInfo LuaJIT 2.1.0-beta3
Linux archlinux 5.15.85-1-lts #1 SMP Thu, 22 Dec 2022 06:22:00 +0000 x86_64 GNU/Linux
9e4c395
vim.g.loaded_netrw = 1 vim.g.loaded_netrwPlugin = 1 require 'nvim-tree'.setup { sync_root_with_cwd = true }
Nvim-tree should open up to where Neovim cwd is.
Nvim-tree opens up in the home directory (where neovim was started originally).
The text was updated successfully, but these errors were encountered:
I'm not quite sure I understand:
:e ~/.config/nvim/lua/alex/init.lua won't change global or local cwd. You'd need to cd .config/nvim/lua for the tree to change directory.
:e ~/.config/nvim/lua/alex/init.lua
cd .config/nvim/lua
Sorry, something went wrong.
Apologies for the noise, this was completely my mistake.
No worries. You might like to try out :help update_focused_file for more automated changes.
:help update_focused_file
No branches or pull requests
Description
When I open a file and Neovim changes cwd, nvim-tree does not follow.
Neovim version
Operating system and version
Linux archlinux 5.15.85-1-lts #1 SMP Thu, 22 Dec 2022 06:22:00 +0000 x86_64 GNU/Linux
nvim-tree version
9e4c395
Minimal config
Steps to reproduce
Expected behavior
Nvim-tree should open up to where Neovim cwd is.
Actual behavior
Nvim-tree opens up in the home directory (where neovim was started originally).
The text was updated successfully, but these errors were encountered: