Skip to content

Commit 88f3ac3

Browse files
folliehiyukichrisbra
authored andcommitted
patch 9.1.2059: filetype: Nickel files are not recognized
Problem: filetype: Nickel files are not recognized Solution: Detect *.ncl files as nickel filetype (Hoang Nguyen) Reference: - https://nickel-lang.org/getting-started/ - https://github.com/tweag/nickel/tree/master/examples closes: #19102 Signed-off-by: Hoang Nguyen <folliekazetani@protonmail.com> Signed-off-by: Christian Brabandt <cb@256bit.org>
1 parent ac5c8ab commit 88f3ac3

3 files changed

Lines changed: 6 additions & 1 deletion

File tree

runtime/autoload/dist/ft.vim

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ vim9script
33
# Vim functions for file type detection
44
#
55
# Maintainer: The Vim Project <https://github.com/vim/vim>
6-
# Last Change: 2026 Jan 02
6+
# Last Change: 2026 Jan 06
77
# Former Maintainer: Bram Moolenaar <Bram@vim.org>
88

99
# These functions are moved here from runtime/filetype.vim to make startup
@@ -2368,6 +2368,8 @@ const ft_from_ext = {
23682368
# N1QL
23692369
"n1ql": "n1ql",
23702370
"nql": "n1ql",
2371+
# Nickel
2372+
"ncl": "nickel",
23712373
# Nim file
23722374
"nim": "nim",
23732375
"nims": "nim",

src/testdir/test_filetype.vim

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -578,6 +578,7 @@ def s:GetFilenameChecks(): dict<list<string>>
578578
neomuttrc: ['Neomuttrc', '.neomuttrc', '.neomuttrc-file', '/.neomutt/neomuttrc', '/.neomutt/neomuttrc-file', 'Neomuttrc', 'Neomuttrc-file', 'any/.neomutt/neomuttrc', 'any/.neomutt/neomuttrc-file', 'neomuttrc', 'neomuttrc-file' ],
579579
netrc: ['.netrc'],
580580
nginx: ['file.nginx', 'nginxfile.conf', 'filenginx.conf', 'any/etc/nginx/file', 'any/usr/local/nginx/conf/file', 'any/nginx/file.conf'],
581+
nickel: ['file.ncl'],
581582
nim: ['file.nim', 'file.nims', 'file.nimble'],
582583
ninja: ['file.ninja'],
583584
nix: ['file.nix'],

src/version.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -734,6 +734,8 @@ static char *(features[]) =
734734

735735
static int included_patches[] =
736736
{ /* Add new patch number below this line */
737+
/**/
738+
2059,
737739
/**/
738740
2058,
739741
/**/

0 commit comments

Comments
 (0)