Merge pull request #13701 from erw7/fix-checkhealth

Fix checkhealth problems
This commit is contained in:
erw7 2021-02-06 13:01:37 +09:00 committed by GitHub
commit 02a9663869
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -42,7 +42,7 @@ function! s:check_config() abort
endif
let writeable = v:true
let shadafile = substitute(matchstr(
let shadafile = empty(&shada) ? &shada : substitute(matchstr(
\ split(&shada, ',')[-1], '^n.\+'), '^n', '', '')
let shadafile = empty(&shadafile) ? empty(shadafile) ?
\ stdpath('data').'/shada/main.shada' : expand(shadafile)
@ -247,6 +247,10 @@ function! s:check_terminal() abort
let kdch1_entry = matchstr(out, 'key_dc=[^,[:space:]]*')
if v:shell_error
\ && (!has('win32')
\ || empty(matchstr(out,
\ 'infocmp: couldn''t open terminfo file .\+'
\ ..'\%(conemu\|vtpcon\|win32con\)')))
call health#report_error('command failed: '.cmd."\n".out)
else
call health#report_info('key_backspace (kbs) terminfo entry: '