From: Guillaume Barbier Date: Thu, 19 Mar 2026 20:24:40 +0000 (+0000) Subject: patch 9.2.0204: filetype: cps files are not recognized X-Git-Tag: v9.2.0204^0 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=53884ba7a8fb22de006689a6feb88fb8f0bd7db9;p=thirdparty%2Fvim.git patch 9.2.0204: filetype: cps files are not recognized Problem: filetype: cps files are not recognized Solution: Detect *.cps files as json filetype (Guillaume Barbier). Reference: https://github.com/cps-org/cps https://cps-org.github.io/cps/ closes: #19758 Signed-off-by: Guillaume Barbier Signed-off-by: Christian Brabandt --- diff --git a/runtime/autoload/dist/ft.vim b/runtime/autoload/dist/ft.vim index a90655febc..dffbf355f2 100644 --- a/runtime/autoload/dist/ft.vim +++ b/runtime/autoload/dist/ft.vim @@ -3,7 +3,7 @@ vim9script # Vim functions for file type detection # # Maintainer: The Vim Project -# Last Change: 2026 Mar 13 +# Last Change: 2026 Mar 19 # Former Maintainer: Bram Moolenaar # These functions are moved here from runtime/filetype.vim to make startup @@ -1789,6 +1789,8 @@ const ft_from_ext = { "cairo": "cairo", # Cap'n Proto "capnp": "capnp", + # Common Package Specification + "cps": "json", # C# "cs": "cs", "csx": "cs", diff --git a/src/testdir/test_filetype.vim b/src/testdir/test_filetype.vim index 735b581241..58e5de13d1 100644 --- a/src/testdir/test_filetype.vim +++ b/src/testdir/test_filetype.vim @@ -419,7 +419,7 @@ def s:GetFilenameChecks(): dict> jovial: ['file.jov', 'file.j73', 'file.jovial'], jproperties: ['file.properties', 'file.properties_xx', 'file.properties_xx_xx', 'some.properties_xx_xx_file', 'org.eclipse.xyz.prefs'], jq: ['file.jq'], - json: ['file.json', 'file.jsonp', 'file.json-patch', 'file.geojson', 'file.webmanifest', 'Pipfile.lock', 'file.ipynb', 'file.jupyterlab-settings', + json: ['file.json', 'file.jsonp', 'file.json-patch', 'file.geojson', 'file.webmanifest', 'Pipfile.lock', 'file.ipynb', 'file.jupyterlab-settings', 'file.cps', '.prettierrc', '.firebaserc', '.stylelintrc', '.lintstagedrc', 'file.slnf', 'file.sublime-project', 'file.sublime-settings', 'file.sublime-workspace', 'file.bd', 'file.bda', 'file.xci', 'flake.lock', 'pack.mcmeta', 'deno.lock', '.swcrc', 'composer.lock', 'symfony.lock'], json5: ['file.json5'], diff --git a/src/version.c b/src/version.c index a93d224132..1463ac6a6c 100644 --- a/src/version.c +++ b/src/version.c @@ -734,6 +734,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 204, /**/ 203, /**/