]> git.ipfire.org Git - thirdparty/vim.git/commitdiff
patch 9.0.2061: not able to detect xkb filetypes v9.0.2061
authorGuido Cella <guido@guidocella.xyz>
Mon, 23 Oct 2023 17:19:46 +0000 (19:19 +0200)
committerChristian Brabandt <cb@256bit.org>
Mon, 23 Oct 2023 17:19:46 +0000 (19:19 +0200)
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>
runtime/filetype.vim
src/testdir/test_filetype.vim
src/version.c

index 6fef4b77a7d9b37c408aeafb43f1c53c8e740fd0..07d6bbfca1d3d22c8bc98e47aba1da32bfe2ca69 100644 (file)
@@ -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')
 
index bfaab514ebbf0871a31385666f966cd820f7b651..f68ad00dd5d0fe63fb46c69cc5079ac1c908af11 100644 (file)
@@ -800,6 +800,7 @@ def s:GetFilenameChecks(): dict<list<string>>
     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'],
index 37a31fdace5e776cace13f8902bab7521ed20d00..a8de25a1f575e844c491eae8a0f2a6c3cdd5112b 100644 (file)
@@ -704,6 +704,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    2061,
 /**/
     2060,
 /**/