diff --git a/lua/fzf-lua/libuv.lua b/lua/fzf-lua/libuv.lua index 273264b..f49f530 100644 --- a/lua/fzf-lua/libuv.lua +++ b/lua/fzf-lua/libuv.lua @@ -460,7 +460,7 @@ end M.wrap_spawn_stdio = function(opts, fn_transform, fn_preprocess) assert(opts and type(opts) == 'string') assert(not fn_transform or type(fn_transform) == 'string') - local nvim_bin = vim.v.argv[1] + local nvim_bin = vim.v.progpath local call_args = opts for _, fn in ipairs({ fn_transform, fn_preprocess }) do if type(fn) == 'string' then diff --git a/lua/fzf-lua/shell.lua b/lua/fzf-lua/shell.lua index bcfc392..df22aef 100644 --- a/lua/fzf-lua/shell.lua +++ b/lua/fzf-lua/shell.lua @@ -52,7 +52,7 @@ function M.raw_async_action(fn, fzf_field_expression, debug) -- this is for windows WSL and AppImage users, their nvim path isn't just -- 'nvim', it can be something else - local nvim_bin = vim.v.argv[1] + local nvim_bin = vim.v.progpath local call_args = ("fzf_lua_server=[[%s]], fnc_id=%d %s"):format( vim.g.fzf_lua_server, id, debug and ", debug=true" or "")