Root directory search should start at the current file, not CWD #35
Closed
LorenzBischof
started this conversation in
General
Replies: 1 comment 3 replies
-
|
I think this sounds fine. My personal workflow is to open the project directory, then fuzzy find files from there. Reading through the docs again it sound like your proposed change would satisfy both use cases. Let me know if you'd like to submit a PR, if not I can get to it later today. |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Currently the root directory is evaluated from the CWD where vim is executed and not the file path itself. Is there a reason for this?
The following function expects a filename:
codesettings.nvim/lua/codesettings/util.lua
Line 33 in d1b18b5
No filename is provided:
codesettings.nvim/lua/codesettings/util.lua
Line 74 in d1b18b5
Which always results in CWD being used:
codesettings.nvim/lua/codesettings/util.lua
Line 50 in d1b18b5
As far as I can tell, the default behavior is similar, if it cannot find a file path:
neovim/neovim#34208
Is there a reason you are not using
vim.fs.root(0, patterns)?I see someone has already reported this, however I propose we change the default: #29
Beta Was this translation helpful? Give feedback.
All reactions