]> git.ipfire.org Git - thirdparty/vim.git/commitdiff
patch 9.1.1694: filetype: Buck eXtension Lang files are not recognized v9.1.1694
authorJade Lovelace <jadel@mercury.com>
Tue, 26 Aug 2025 19:28:02 +0000 (21:28 +0200)
committerChristian Brabandt <cb@256bit.org>
Tue, 26 Aug 2025 19:28:02 +0000 (21:28 +0200)
Problem:  filetype: Buck eXtension Lang files are not recognized
Solution: Detect *.bxl files as bzl filetype.
          (Jade Lovelace)

References:
- https://buck2.build/docs/bxl/

closes: #18130

Signed-off-by: Jade Lovelace <jadel@mercury.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
runtime/filetype.vim
src/testdir/test_filetype.vim
src/version.c

index af21a47fb749ac64b6916aa0ea334efaa7bc968b..ab5a0b7b5ac3ff64cb3c949444406426044d50a3 100644 (file)
@@ -319,7 +319,7 @@ au BufNewFile,BufRead *.brs                 setf brightscript
 au BufNewFile,BufRead *.bsd,*.bsdl                     setf bsdl
 
 " Bazel (https://bazel.build) and Buck2 (https://buck2.build/)
-autocmd BufRead,BufNewFile *.bzl,*.bazel,WORKSPACE,WORKSPACE.bzlmod    setf bzl
+autocmd BufRead,BufNewFile *.bzl,*.bxl,*.bazel,WORKSPACE,WORKSPACE.bzlmod      setf bzl
 if has("fname_case")
   " There is another check for BUILD and BUCK further below.
   autocmd BufRead,BufNewFile *.BUILD,BUILD,BUCK                setf bzl
index 43d103908d2e24e79bd2531b31d05878123d1343..faa1d04cb7f6ebc677de1049877ee9fd4020516c 100644 (file)
@@ -152,7 +152,7 @@ def s:GetFilenameChecks(): dict<list<string>>
     brightscript: ['file.brs'],
     bsdl: ['file.bsd', 'file.bsdl'],
     bst: ['file.bst'],
-    bzl: ['file.bazel', 'file.bzl', 'WORKSPACE', 'WORKSPACE.bzlmod'],
+    bzl: ['file.bazel', 'file.bzl', 'file.bxl', 'WORKSPACE', 'WORKSPACE.bzlmod'],
     bzr: ['bzr_log.any', 'bzr_log.file'],
     c: ['enlightenment/file.cfg', 'file.qc', 'file.c', 'some-enlightenment/file.cfg', 'file.mdh', 'file.epro'],
     c3: ['file.c3', 'file.c3i', 'file.c3t'],
index 4993aa8d451757ee615020528ff7d442a5260ce6..a28eef78fab75dea1f5e6a7ea198913f2b381b3e 100644 (file)
@@ -724,6 +724,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    1694,
 /**/
     1693,
 /**/