changeset 33642:2d48081760a0 v9.0.2061

patch 9.0.2061: not able to detect xkb filetypes Commit: https://github.com/vim/vim/commit/ae9021a840db3253b0e0cb84186faae73368afd7 Author: Guido Cella <guido@guidocella.xyz> Date: Mon Oct 23 19:19:46 2023 +0200 patch 9.0.2061: not able to detect xkb filetypes Problem: not able to detect xkb filetypes Solution: Detect files below /u/s/X11/xkb as xkb files (without adding an extra filetype) Those files are used from the X11 xkb extension closes: #13401 Signed-off-by: Christian Brabandt <cb@256bit.org> Co-authored-by: Guido Cella <guido@guidocella.xyz>
author Christian Brabandt <cb@256bit.org>
date Mon, 23 Oct 2023 19:30:06 +0200
parents be8288cd6548
children 17c34403314e
files runtime/filetype.vim src/testdir/test_filetype.vim src/version.c
diffstat 3 files changed, 6 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/runtime/filetype.vim
+++ b/runtime/filetype.vim
@@ -2862,6 +2862,9 @@ au BufNewFile,BufRead XF86Config*
 	\|endif
 	\|call s:StarSetf('xf86conf')
 
+" XKB
+au BufNewFile,BufRead */usr/share/X11/xkb/{compat,geometry,keycodes,symbols,types}/*	call s:StarSetf('xkb')
+
 " X11 xmodmap
 au BufNewFile,BufRead *xmodmap*			call s:StarSetf('xmodmap')
 
--- a/src/testdir/test_filetype.vim
+++ b/src/testdir/test_filetype.vim
@@ -800,6 +800,7 @@ def s:GetFilenameChecks(): dict<list<str
     xf86conf: ['xorg.conf', 'xorg.conf-4'],
     xhtml: ['file.xhtml', 'file.xht'],
     xinetd: ['/etc/xinetd.conf', '/etc/xinetd.d/file', 'any/etc/xinetd.conf', 'any/etc/xinetd.d/file'],
+    xkb: ['/usr/share/X11/xkb/compat/pc', '/usr/share/X11/xkb/geometry/pc', '/usr/share/X11/xkb/keycodes/evdev', '/usr/share/X11/xkb/symbols/pc', '/usr/share/X11/xkb/types/pc'],
     xmath: ['file.msc', 'file.msf'],
     xml: ['/etc/blkid.tab', '/etc/blkid.tab.old', 'file.xmi', 'file.csproj', 'file.csproj.user', 'file.fsproj', 'file.fsproj.user', 'file.vbproj', 'file.vbproj.user', 'file.ui', 'file.tpm', '/etc/xdg/menus/file.menu', 'fglrxrc', 'file.xlf', 'file.xliff', 'file.xul', 'file.wsdl', 'file.wpl', 'any/etc/blkid.tab', 'any/etc/blkid.tab.old', 'any/etc/xdg/menus/file.menu', 'file.atom', 'file.rss', 'file.cdxml', 'file.psc1', 'file.mpd'],
     xmodmap: ['anyXmodmap', 'Xmodmap', 'some-Xmodmap', 'some-xmodmap', 'some-xmodmap-file', 'xmodmap', 'xmodmap-file'],
--- 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 */
 /**/
+    2061,
+/**/
     2060,
 /**/
     2059,