From: Luis Davim Date: Tue, 20 Jan 2026 19:40:35 +0000 (+0000) Subject: patch 9.1.2100: filetype: tiltfiles are not recognized X-Git-Tag: v9.1.2100^0 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ff0e5d994ca4b533f3c9c43a7a154276b0fa08fb;p=thirdparty%2Fvim.git patch 9.1.2100: filetype: tiltfiles are not recognized Problem: filetype: tiltfiles are not recognized Solution: Detect Tiltfiles.* and *.tiltfiles as tiltfile filetype. (Luis Davim) Reference: - https://docs.tilt.dev/api.html fixes: #19214 closes: #19218 Signed-off-by: Luis Davim Signed-off-by: Christian Brabandt --- diff --git a/runtime/autoload/dist/ft.vim b/runtime/autoload/dist/ft.vim index 3f3fe971a5..0d3b1e7ebf 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 Jan 11 +# Last Change: 2026 Jan 20 # Former Maintainer: Bram Moolenaar # These functions are moved here from runtime/filetype.vim to make startup @@ -3033,6 +3033,9 @@ const ft_from_ext = { "blp": "blueprint", # Blueprint build system file "bp": "bp", + # Tiltfile + "Tiltfile": "tiltfile", + "tiltfile": "tiltfile" } # Key: file name (the final path component, excluding the drive and root) # Value: filetype @@ -3319,6 +3322,9 @@ const ft_from_name = { # TF (TinyFugue) mud client ".tfrc": "tf", "tfrc": "tf", + # Tilefile + "Tiltfile": "tiltfile", + "tiltfile": "tiltfile", # Trustees "trustees.conf": "trustees", # Vagrant (uses Ruby syntax) diff --git a/runtime/filetype.vim b/runtime/filetype.vim index da5340a320..bfdf46e1a8 100644 --- a/runtime/filetype.vim +++ b/runtime/filetype.vim @@ -1,7 +1,7 @@ " Vim support file to detect file types " " Maintainer: The Vim Project -" Last Change: 2026 Jan 11 +" Last Change: 2026 Jan 20 " Former Maintainer: Bram Moolenaar " If the filetype can be detected from extension or file name(the final path component), @@ -1548,6 +1548,9 @@ au BufNewFile,BufRead .tcshrc* call dist#ft#SetFileTypeShell("tcsh") " csh scripts ending in a star au BufNewFile,BufRead .login*,.cshrc* call dist#ft#CSH() +" Tiltfile +au BufNewFile,BufRead Tiltfile.* call s:StarSetf('tiltfile') + " tmux configuration with arbitrary extension au BufNewFile,BufRead {.,}tmux*.conf* call s:StarSetf('tmux') diff --git a/src/testdir/test_filetype.vim b/src/testdir/test_filetype.vim index 625a4f90ad..a082b4fb9f 100644 --- a/src/testdir/test_filetype.vim +++ b/src/testdir/test_filetype.vim @@ -888,6 +888,7 @@ def s:GetFilenameChecks(): dict> tidy: ['.tidyrc', 'tidyrc', 'tidy.conf'], tiger: ['file.tig'], tilde: ['file.t.html'], + tiltfile: ['Tiltfile', 'tiltfile', 'file.Tiltfile', 'file.tiltfile', 'Tiltfile.debian'], tla: ['file.tla'], tli: ['file.tli'], tmux: ['tmuxfile.conf', '.tmuxfile.conf', '.tmux-file.conf', '.tmux.conf', 'tmux-file.conf', 'tmux.conf', 'tmux.conf.local'], diff --git a/src/version.c b/src/version.c index 71388c23ed..61720c9361 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 */ +/**/ + 2100, /**/ 2099, /**/