junegunn / fzf.vim

fzf :heart: vim
MIT License
9.63k stars 585 forks source link

Unusable on windows #350

Open rr- opened 7 years ago

rr- commented 7 years ago
Error running /bin/zsh "/tmp/v78cWNw/4"|"/cygdrive/z/.fzf/bin/fzf"  -m  --prompt '~/s/dotfiles/' --expect=ctrl-v,ctrl-x,ctrl-t --height=28 > /tmp/v78cWNw/3

https://github.com/junegunn/fzf/blob/master/src/options.go#L829-L831

$ fzf --version
0.16.6

Normal fzf works.

junegunn commented 7 years ago

Normal fzf works.

Are you sure about this? fzf doesn't run on Cygwin.

rr- commented 7 years ago

I am positive - I've installed golang by hand (had to provide some environment variables) and ran ~/.fzf/install that worked like a charm. Executing fzf without any option in a given directory shows the filenames, and ^R reverse history search works as well IIRC. So it's just :Ag and :Files in Vim.

junegunn commented 7 years ago

Interesting, I'll try it when I get a chance.

junegunn commented 7 years ago

Hmm, by the way, last time I checked golang didn't support cygwin.

rr- commented 7 years ago

Even if it doesn't it works: http://dgtech.ga/2016/01/27/cygwin-go/

I mean, it runs inside cygwin shell without problems, and the fzf that is built by it works nice as well. You're right in the sense that there are no builds targeted for cygwin.

johnzeng commented 7 years ago

+1 , fzf works, but fzf.vim doesn't because there is an output to /tmp

janlazo commented 7 years ago

Initial attempt in supporting cygwin in the vim plugin via cygpath and Windows binary of fzf https://github.com/janlazo/fzf/blob/vim/shellesc_cygwin/plugin/fzf.vim

bash/sh.exe in cygwin uses cmd.exe under the hood so /tmp doesn't actually exist.

janlazo commented 7 years ago

@johnzeng @rr Can you test on the latest fzf? The vim plugin has basic support for cygwin.

janlazo commented 7 years ago

Latest fzf and fzf.vim have Windows support with or without msysgit or cygwin.