Closed icthus56 closed 2 years ago
I had the same issue, after checking https://github.com/junegunn/fzf.vim/issues/1368
I figured that my issue was there because I had a custom shell:
$HOME/.config/nvim/init.vim
set shell=mycustonshell
~/.local/bin/mycustomshell
#!/bin/zsh
# ... Some strange hackery code
zsh
I fixed my issue by setting shell to zsh
$HOME/.config/nvim/init.vim
set shell=zsh
I wonder if there is an issue with the shell detection and escaping. Unfortunately I cannot set my shell to zsh as I am in Windows. I'm perplexed that it seems like I'm the only one with the issue though....
@junegunn do you have any idea where this escaping issue comes from or what I can modify to get FZF working under Win10? Thanks.
@icthus56 I am on Win10 and the same thing was happening to me. I had set my shell to powershell
instead of the default of C:\Windows\system32\cmd.exe
. Once I reverted back to the default shell, I was able to get :Files
to work. You can see the current value of your shell by typing :echo &shell
in vim. Hope this helps.
@jrudel Thanks, your comment helped to find my issue. It turned out that shellxescape was set somwhere deep. Thanks for your help.
man fzf
)In gvim when launching fzf via files, the following external command is executed: C:\WINDOWS\system32\cmd.exe /c (^(C:\Users\leessy\vimfiles\bundle\fzf/bin/fzf --version --no-height^) >C:\Users\leessy\AppData\Local\Temp\VIo13CB.tmp 2>^&1
There seems to be an issue with the "2>^&1" as passing "2>&1" directly to the gvim command line results in a successful execution. The full path to fzf binary is given, so that is not the issue.
See below for the error that results from the "Files" command: