mirror of
https://github.com/junegunn/fzf.git
synced 2024-09-11 14:35:26 +03:00
[vim] Fix version check on windows/powershell (addendum)
Should handle powershell.exe as well Fix https://github.com/junegunn/fzf.vim/issues/1411
This commit is contained in:
parent
3c08dca7e7
commit
e5d8cbd383
@ -164,7 +164,7 @@ function s:get_version(bin)
|
|||||||
if has_key(s:versions, a:bin)
|
if has_key(s:versions, a:bin)
|
||||||
return s:versions[a:bin]
|
return s:versions[a:bin]
|
||||||
end
|
end
|
||||||
let command = (&shell == 'powershell' ? '&' : '') . shellescape(a:bin) . ' --version --no-height'
|
let command = (&shell =~ 'powershell' ? '&' : '') . shellescape(a:bin) . ' --version --no-height'
|
||||||
let output = systemlist(command)
|
let output = systemlist(command)
|
||||||
if v:shell_error || empty(output)
|
if v:shell_error || empty(output)
|
||||||
return ''
|
return ''
|
||||||
|
Loading…
Reference in New Issue
Block a user