win: health.vim/check_ruby(): find gem.cmd #6608

gem.cmd is not found by system(['gem', ...]), pass it to cmd.exe.
This commit is contained in:
Justin M. Keyes
2017-04-28 16:41:16 +02:00
parent 9f6d693e26
commit 51a2d8dc36

View File

@@ -445,7 +445,7 @@ function! s:check_ruby() abort
endif endif
call health#report_info('Host: '. host) call health#report_info('Host: '. host)
let latest_gem_cmd = 'gem list -ra ^neovim$' let latest_gem_cmd = has('win32') ? 'cmd /c gem list -ra ^^neovim$' : 'gem list -ra ^neovim$'
let latest_gem = s:system(split(latest_gem_cmd)) let latest_gem = s:system(split(latest_gem_cmd))
if s:shell_error || empty(latest_gem) if s:shell_error || empty(latest_gem)
call health#report_error('Failed to run: '. latest_gem_cmd, call health#report_error('Failed to run: '. latest_gem_cmd,