vim-grepper icon indicating copy to clipboard operation
vim-grepper copied to clipboard

Do not assume shell for platform

Open Sh3Rm4n opened this issue 4 years ago • 0 comments

win32 does not necessarily mean cmd.exe as well as others does not mean sh.

Problem is, that previous functions, like s:escape_cword() do respect shell e.g. with shellescape(), but passing the arguments to job_start() / jobstart() does ignore shell.

This leads to trouble. E.g. I use fish, where shellescape() escapes \, which means if <cword> / -cword is used (e.g. Aword), s:escape_cword() results to \\bAword\\b (which is correct), but this string is then passed to jobstart() executed by sh, which does not share the same escaping rules.

Sh3Rm4n avatar Oct 10 '21 17:10 Sh3Rm4n