changeset 35081:717d459ee5cb v9.1.0382

patch 9.1.0382: filetype: Kbuild files are not recognized Commit: https://github.com/vim/vim/commit/5cbc9a69e529361e1725f422b8cd6157fe0adc33 Author: Bruno BELANYI <bruno@belanyi.fr> Date: Tue Apr 30 20:16:01 2024 +0200 patch 9.1.0382: filetype: Kbuild files are not recognized Problem: Kbuild files are not recognized. Solution: Detect Kbuild files as make files. (Bruno Belanyi) closes: #14676 Signed-off-by: Bruno Belanyi <bruno@belanyi.fr> Signed-off-by: Christian Brabandt <cb@256bit.org>
author Christian Brabandt <cb@256bit.org>
date Tue, 30 Apr 2024 20:30:09 +0200
parents fcc356d45610
children b26193581057
files runtime/filetype.vim src/testdir/test_filetype.vim src/version.c
diffstat 3 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/runtime/filetype.vim
+++ b/runtime/filetype.vim
@@ -1356,6 +1356,7 @@ au BufNewFile,BufRead .mailcap,mailcap		
 
 " Makefile
 au BufNewFile,BufRead *[mM]akefile,*.mk,*.mak,*.dsp setf make
+au BufNewFile,BufRead Kbuild setf make
 
 " MakeIndex
 au BufNewFile,BufRead *.ist,*.mst		setf ist
--- a/src/testdir/test_filetype.vim
+++ b/src/testdir/test_filetype.vim
@@ -417,7 +417,7 @@ def s:GetFilenameChecks(): dict<list<str
     mail: ['snd.123', '.letter', '.letter.123', '.followup', '.article', '.article.123', 'pico.123', 'mutt-xx-xxx', 'muttng-xx-xxx', 'ae123.txt', 'file.eml', 'reportbug-file'],
     mailaliases: ['/etc/mail/aliases', '/etc/aliases', 'any/etc/aliases', 'any/etc/mail/aliases'],
     mailcap: ['.mailcap', 'mailcap'],
-    make: ['file.mk', 'file.mak', 'file.dsp', 'makefile', 'Makefile', 'makefile-file', 'Makefile-file', 'some-makefile', 'some-Makefile'],
+    make: ['file.mk', 'file.mak', 'file.dsp', 'makefile', 'Makefile', 'makefile-file', 'Makefile-file', 'some-makefile', 'some-Makefile', 'Kbuild'],
     mallard: ['file.page'],
     man: ['file.man'],
     manconf: ['/etc/man.conf', 'man.config', 'any/etc/man.conf'],
--- a/src/version.c
+++ b/src/version.c
@@ -705,6 +705,8 @@ static char *(features[]) =
 static int included_patches[] =
 {   /* Add new patch number below this line */
 /**/
+    382,
+/**/
     381,
 /**/
     380,