jremmen / vim-ripgrep

Use RipGrep in Vim and display results in a quickfix list
MIT License
540 stars 99 forks source link

Fish pipe compatibility issues #41

Open miki725 opened 5 years ago

miki725 commented 5 years ago

Current shellpipe="&>" is incompatible with fish which results in error something like:

fish: Expected a command, but instead found a redirection
rg --vimgrep -i foo &> /var/folders/4z/bxmdspnn5qs9x0bbz8w7cbrw0000gn/T/nvimzCL1HW/4

fish is enabled via in ~/.config/nvim/init.vim:

set shell=fish

https://github.com/jremmen/vim-ripgrep/blob/ec87af6b69387abb3c4449ce8c4040d2d00d745e/plugin/vim-ripgrep.vim#L89

ColinKennedy commented 2 years ago

Also noting here that, with a tcsh shell, the default shellpipe is |& tee. Since vim-ripgrep tries to set let &shellpipe="&>", it causes the search to fail. Removing the let &shellpipe="&>" completely worked for me to fix the issue.