neovim/runtime/ftplugin/checkhealth.vim
Alexandre Teoi 4382d2ed56
feat(health): fold successful healthchecks #22866
Problem:
checkhealth can be noisy, but we don't want to omit info.

Solution:
Fold OK results by default, if 'foldenable' is enabled.
Resolves #22796
2023-06-06 08:42:26 -07:00

22 lines
567 B
VimL

" Vim filetype plugin
" Language: Nvim :checkhealth buffer
" Last Change: 2022 Nov 10
if exists("b:did_ftplugin")
finish
endif
runtime! ftplugin/help.vim
setlocal wrap breakindent linebreak
setlocal foldexpr=getline(v:lnum-1)=~'^=\\{78}$'?'>1':(getline(v:lnum)=~'^=\\{78}'?0:'=')
setlocal foldmethod=expr
setlocal foldtext=v:lua.require('vim.health').foldtext()
let &l:iskeyword='!-~,^*,^|,^",192-255'
if exists("b:undo_ftplugin")
let b:undo_ftplugin .= "|setl wrap< bri< lbr< kp< isk<"
else
let b:undo_ftplugin = "setl wrap< bri< lbr< kp< isk<"
endif