patch 9.2.0559: filetype: Kaitai struct files are not recogonized

Problem:  filetype: Kaitai struct files are not recogonized
Solution: Detect *.ksy files as yaml filetype (Wu, Zhenyu)

Reference:
https://doc.kaitai.io/

closes: #20353

Signed-off-by: Wu, Zhenyu <wuzhenyu@ustc.edu>
Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
Wu, Zhenyu
2026-05-29 18:25:25 +00:00
committed by Christian Brabandt
parent 339b523657
commit 73e619d699
3 changed files with 5 additions and 1 deletions
+2
View File
@@ -2336,6 +2336,8 @@ const ft_from_ext = {
"kts": "kotlin",
# KDE script
"ks": "kscript",
# Kaitai struct
"ksy": "yaml",
# Kyaml
"kyaml": "yaml",
"kyml": "yaml",
+1 -1
View File
@@ -996,7 +996,7 @@ def s:GetFilenameChecks(): dict<list<string>>
xslt: ['file.xsl', 'file.xslt'],
yacc: ['file.yy', 'file.yxx', 'file.y++'],
yaml: ['file.yaml', 'file.yml', 'file.eyaml', 'file.kyaml', 'file.kyml', 'any/.bundle/config', '.clangd', '.clang-format', '.clang-tidy', 'file.mplstyle', 'matplotlibrc', 'yarn.lock',
'/home/user/.kube/config', '/home/user/.kube/kuberc', '.condarc', 'condarc', '.mambarc', 'mambarc', 'pixi.lock', 'buf.lock'],
'/home/user/.kube/config', '/home/user/.kube/kuberc', '.condarc', 'condarc', '.mambarc', 'mambarc', 'pixi.lock', 'buf.lock', 'file.ksy'],
yang: ['file.yang'],
yara: ['file.yara', 'file.yar'],
yuck: ['file.yuck'],
+2
View File
@@ -729,6 +729,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
559,
/**/
558,
/**/