-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
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
nvim binary: use 'vim.v.progpath' instead of 'vim.v.argv[1]' #47
Conversation
Didn't think of that, thank you! |
You're welcome @vijaymarupudi! Every fix of importance in fzf-lua I also try to PR here, on this note there's another imporvement I added to fzf-lua which might be of interest to you, instead of piping the command into fzf I now use a temporary environment variable
You can confirm what I'm saying in junegunn/fzf#1750 (comment):
I can quickly PR it for you if you wish, lmk. |
I think this broke the plugin for me, when I try to use I'm on NixOS, and vim.v.progpath looks ok. It's working fine on |
You're correct, I applied the same code from |
@3rd should be fixed now |
When the user opens neovim using a relative path and then uses
:cd
to change the working directory the neovim binary path (used in the shell helper) will be have the wrong path and fail to run.I encountered this in fzf-lua when using the nightly binary tar and opening neovim with
./nvim/...
after usingcd
once the path provided byvim.v.argv[1]
no longer works.Using
v:progpath
is safer and always provides the full path of the neovim binary.