kyazdani42 / nvim-tree.lua

A file explorer tree for neovim written in lua

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Use relative path to find file

kuznetsss opened this issue · comments

I think using absolute path in searching for file is wrong because there could be symlinks.

For example in my system I open file from home directory:
~$ nvim Documents/vimwiki/
But Documents is symlink Documents -> /mnt/Data/home_user/Documents
So the real absolute file path is /mnt/Data/home_user/Documents/vimwiki/ which nvim-tree tries to find being in /home/user directory. So the file can't be found.

I think it would be better to search file by relative path from nvim's cwd.

you are correct, we should be searching by relative path. You could open a PR if i didn't fix this by the end of the day.

ezoic increase your site revenue