Revert the change introduced in #552. It seems that the startup time
difference between bash and fish is not much of an issue now.
> time bash -c 'date'
Thu Feb 13 21:15:03 KST 2020
real 0m0.008s
user 0m0.003s
sys 0m0.003s
> time fish -c 'date'
Thu Feb 13 21:15:05 KST 2020
real 0m0.014s
user 0m0.007s
sys 0m0.006s
When we explicitly *pipe* $FZF_DEFAULT_COMMAND instead of making fzf
internally start the process ($FZF_DEFAULT_COMMAND | fzf), fzf may hang
if the input process doesn't quickly process SIGPIPE and abort.
Also, fzf#vim#grep temporarily swaps $FZF_DEFAULT_COMMAND instead of
setting 'sink' so fzf can kill the default command on 'reload'.
https://github.com/junegunn/fzf.vim/issues/927
However, because of the "pipe conversion", the trick wasn't working as
expected.
467c327788/autoload/fzf/vim.vim (L720-L726)
We can go even further and always set $FZF_DEFAULT_COMMAND instead of
piping source command.
* Add MSYS2 support as a vim plugin
Add &shellcmdflag and TERM environment variable treatment.
- Make &shellcmdflag `/C` when &shell turns into `cmd.exe`
- Delete %TERM% environment variable before fzf execution
* Change shellescape default value depending on s:is_win flag
* Make TERM environment empty only when gui is running
* Stop checking &shell in fzf#shellescape function
This funcion's behavior is controlled by only if it is Windows or not.
So there is no need to check &shell.
* Take neovim into consideration when to set shellcmdflag
* Add &shellxquote control
This commit fixes a bug where lines that declare multiple hostnames get
omitted from completion entirely if one of the hostnames matches *. For
example:
Host foo.com bar.dev baz.*
The zsh version of the cd widget sets the variable `dir` to the path of
the target directory before invoking `cd`. This causes zsh to treat the
target directory as a named directory, which has the effect of zsh
substituting '%~' with '~dir' instead of the proper path when it
performs prompt expansion.
This commit will cause the widget to unset `dir` before redrawing the
prompt to fix this issue.
Details of zsh prompt expansion can be found in:
http://zsh.sourceforge.net/Doc/Release/Prompt-Expansion.html