]> git.ipfire.org Git - thirdparty/vim.git/commitdiff
patch 9.1.0962: filetype: bun.lock file is not recognized v9.1.0962
authorAnton Kastritskii <halloy52@gmail.com>
Thu, 26 Dec 2024 14:16:12 +0000 (15:16 +0100)
committerChristian Brabandt <cb@256bit.org>
Thu, 26 Dec 2024 14:16:12 +0000 (15:16 +0100)
Problem:  filetype: bun.lock file is not recognized
Solution: detect 'bun.lock' file as jsonc filetype
          (Anton Kastritskii)

closes: #16308

Signed-off-by: Anton Kastritskii <halloy52@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
runtime/filetype.vim
src/testdir/test_filetype.vim
src/version.c

index 538df770b50df513c7fa640ada642505f53727f6..1aca135cd223b34e15210343598f4f21c2259349 100644 (file)
@@ -1263,7 +1263,7 @@ au BufNewFile,BufRead *.sublime-project,*.sublime-settings,*.sublime-workspace    s
 au BufNewFile,BufRead .prettierrc,.firebaserc,.stylelintrc,.lintstagedrc,flake.lock,deno.lock  setf json
 
 " JSONC (JSON with comments)
-au BufNewFile,BufRead *.jsonc,.babelrc,.eslintrc,.jsfmtrc      setf jsonc
+au BufNewFile,BufRead *.jsonc,.babelrc,.eslintrc,.jsfmtrc,bun.lock     setf jsonc
 au BufNewFile,BufRead .jshintrc,.jscsrc,.vsconfig,.hintrc,.swrc,[jt]sconfig*.json      setf jsonc
 
 " JSON
index 09e900f3299c2a225b451ae031d1cc665f6d9c2f..27ced5207177ff2a94b1c328638486fefb766307 100644 (file)
@@ -394,7 +394,7 @@ def s:GetFilenameChecks(): dict<list<string>>
     '.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'],
     json5: ['file.json5'],
-    jsonc: ['file.jsonc', '.babelrc', '.eslintrc', '.jsfmtrc', '.jshintrc', '.jscsrc', '.vsconfig', '.hintrc', '.swrc', 'jsconfig.json', 'tsconfig.json', 'tsconfig.test.json', 'tsconfig-test.json', '.luaurc'],
+    jsonc: ['file.jsonc', '.babelrc', '.eslintrc', '.jsfmtrc', '.jshintrc', '.jscsrc', '.vsconfig', '.hintrc', '.swrc', 'jsconfig.json', 'tsconfig.json', 'tsconfig.test.json', 'tsconfig-test.json', '.luaurc', 'bun.lock'],
     jsonl: ['file.jsonl'],
     jsonnet: ['file.jsonnet', 'file.libsonnet'],
     jsp: ['file.jsp'],
index 8f74c1d7e6e7f459de2b6d73ba93408859e6acb1..c46e3427255a936f8c5abd8c0e40364e3d6c098a 100644 (file)
@@ -704,6 +704,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    962,
 /**/
     961,
 /**/