Following the approach used in other syntax definitions, add support for defining the "syntax sync minlines=..." values for kconfig files in users' ~/.vimrc files, to allow the users to adjust that value in case syntax highlighting stops working for some of the files they edit.
Signed-off-by: Dragan Simic <dsi...@manjaro.org> --- runtime/syntax/kconfig.vim | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/runtime/syntax/kconfig.vim b/runtime/syntax/kconfig.vim index 0aecc0006085..62e47471a554 100644 --- a/runtime/syntax/kconfig.vim +++ b/runtime/syntax/kconfig.vim @@ -1,7 +1,7 @@ " Vim syntax file " Maintainer: Christian Brabandt <c...@256bit.org> " Previous Maintainer: Nikolai Weibull <n...@bitwi.se> -" Latest Revision: 2024-07-19 +" Latest Revision: 2025-01-19 " License: Vim (see :h license) " Repository: https://github.com/chrisbra/vim-kconfig @@ -587,8 +587,6 @@ syn match kconfigConfOptExprGrpE ')' \ kconfigConfOptExprOr \ skipwhite skipnl -syn sync minlines=50 - hi def link kconfigTodo Todo hi def link kconfigComment Comment hi def link kconfigKeyword Keyword @@ -715,6 +713,11 @@ syn region kconfigHelpText \ skip='^$' \ end='^\z1\@!' +if !exists("kconfig_minlines") + let kconfig_minlines = 50 +endif +exec "syn sync minlines=" . kconfig_minlines + hi def link kconfigTodo Todo hi def link kconfigComment Comment hi def link kconfigKeyword Keyword -- -- You received this message from the "vim_dev" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php --- You received this message because you are subscribed to the Google Groups "vim_dev" group. To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscr...@googlegroups.com. To view this discussion visit https://groups.google.com/d/msgid/vim_dev/986178bf95b42d54906e920652ccfa1d282d9f3d.1737308250.git.dsimic%40manjaro.org.