man fzf)I run fzf in Windows 10, and it works as expected in the cmd box for the call fzf --filter="tmp" which will give a list of findings.
When I try to use it in Emacs, it fails to capture the output. I consulted in the Emacs help maillist, and it suggested that It looks like fzf uses direct screen I/O? If so, this won't work on Windows when stdout is a pipe, which is what happens when Emacs on Windows runs a subprocess. Whether could we make fzf run with pipes as stdin/stdout?
Best Regards,
I'm not an Emacs user, so I can't really answer the question, but fzf is designed to work with stdin/stdout pipes.
seq 10 | fzf | cowsay
This is possible because fzf reads from /dev/tty instead of stdin, and prints the finder to stderr instead of stdout. So make sure that stderr of the process is not captured by Emacs. On Vim, system('no-such-command') captures stderr as well, so we use built-in terminal to start fzf instead of using system().
Most helpful comment
I'm not an Emacs user, so I can't really answer the question, but fzf is designed to work with stdin/stdout pipes.
This is possible because fzf reads from
/dev/ttyinstead of stdin, and prints the finder to stderr instead of stdout. So make sure that stderr of the process is not captured by Emacs. On Vim,system('no-such-command')captures stderr as well, so we use built-in terminal to start fzf instead of usingsystem().