mirror of
https://github.com/neovim/neovim.git
synced 2025-12-11 17:12:40 +00:00
health.vim: validate g:clipboard
Closes #7020
Also fix 'iskeyword' setting, which I fumbled in
440133e0d5
This commit is contained in:
@@ -33,7 +33,8 @@ function! health#check(plugin_names) abort
|
|||||||
setlocal wrap breakindent
|
setlocal wrap breakindent
|
||||||
setlocal filetype=markdown
|
setlocal filetype=markdown
|
||||||
setlocal conceallevel=2 concealcursor=nc
|
setlocal conceallevel=2 concealcursor=nc
|
||||||
setlocal keywordprg=:help iskeyword=@,48-57,_,192-255,-,#
|
setlocal keywordprg=:help
|
||||||
|
let &l:iskeyword='!-~,^*,^|,^",192-255'
|
||||||
call s:enhance_syntax()
|
call s:enhance_syntax()
|
||||||
|
|
||||||
if empty(healthchecks)
|
if empty(healthchecks)
|
||||||
|
|||||||
@@ -125,6 +125,10 @@ function! s:check_clipboard() abort
|
|||||||
call health#report_warn(
|
call health#report_warn(
|
||||||
\ 'No clipboard tool found. Clipboard registers will not work.',
|
\ 'No clipboard tool found. Clipboard registers will not work.',
|
||||||
\ [':help clipboard'])
|
\ [':help clipboard'])
|
||||||
|
elseif exists('g:clipboard') && (type({}) != type(g:clipboard)
|
||||||
|
\ || !has_key(g:clipboard, 'copy') || !has_key(g:clipboard, 'paste'))
|
||||||
|
call health#report_error(
|
||||||
|
\ 'g:clipboard exists but is malformed. It must be a dictionary with the keys documented at :help g:clipboard')
|
||||||
else
|
else
|
||||||
call health#report_ok('Clipboard tool found: '. clipboard_tool)
|
call health#report_ok('Clipboard tool found: '. clipboard_tool)
|
||||||
endif
|
endif
|
||||||
|
|||||||
Reference in New Issue
Block a user