0
0
mirror of https://github.com/vim/vim.git synced 2025-09-15 23:23:38 -04:00

check.vim complains about overlong comment lines

Problem:  check.vim complains about overlong comment lines
Solution: only check the length of non-commented lines

Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
Christian Brabandt 2024-05-30 09:51:47 +02:00
parent ed43711b66
commit 32a5faa6d7
No known key found for this signature in database
GPG Key ID: F3F92DA383FDDE09

View File

@ -226,8 +226,8 @@ elseif ctu
" endif
endif
" Check that all lines are no longer than 80 chars
let overlong = search('\%>80v', 'n')
" Check that no lines are longer than 80 chars (except comments)
let overlong = search('^[^#]\%>80v', 'n')
if overlong > 0
echomsg "Lines should be wrapped at 80 columns"
" TODO: make this an error