changeset 35099:05c99aa1c455 v9.1.0389

patch 9.1.0389: filetype: templ files are not recognized Commit: https://github.com/vim/vim/commit/54e79157c536c631b2f9b3dfefec30b9b966ed97 Author: tris203 <admin@snappeh.com> Date: Thu May 2 13:08:25 2024 +0200 patch 9.1.0389: filetype: templ files are not recognized Problem: filetype: templ files are not recognized Solution: Detect '*.templ' files as filetype templ (Tristan Knight) See: - https://github.com/a-h/templ - https://templ.guide/ closes: #14697 Signed-off-by: tris203 <admin@snappeh.com> Signed-off-by: Christian Brabandt <cb@256bit.org>
author Christian Brabandt <cb@256bit.org>
date Thu, 02 May 2024 13:15:19 +0200
parents cd1413ae3cfd
children 2307bd162920
files runtime/filetype.vim src/testdir/test_filetype.vim src/version.c
diffstat 3 files changed, 6 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/runtime/filetype.vim
+++ b/runtime/filetype.vim
@@ -2383,6 +2383,9 @@ au BufNewFile,BufRead *.tcl,*.tm,*.tk,*.
 " Xilinx's xsct and xsdb use tcl
 au BufNewFile,BufRead .xsctcmdhistory,.xsdbcmdhistory	setf tcl
 
+" templ 
+au BufNewFile,BufRead *.templ			setf templ
+
 " Teal
 au BufRead,BufNewFile *.tl			setf teal
 
--- a/src/testdir/test_filetype.vim
+++ b/src/testdir/test_filetype.vim
@@ -747,6 +747,7 @@ def s:GetFilenameChecks(): dict<list<str
     tcl: ['file.tcl', 'file.tm', 'file.tk', 'file.itcl', 'file.itk', 'file.jacl', '.tclshrc', 'tclsh.rc', '.wishrc', '.tclsh-history', '.xsctcmdhistory', '.xsdbcmdhistory'],
     tablegen: ['file.td'],
     teal: ['file.tl'],
+    templ: ['file.templ'],
     template: ['file.tmpl'],
     teraterm: ['file.ttl'],
     terminfo: ['file.ti'],
--- a/src/version.c
+++ b/src/version.c
@@ -705,6 +705,8 @@ static char *(features[]) =
 static int included_patches[] =
 {   /* Add new patch number below this line */
 /**/
+    389,
+/**/
     388,
 /**/
     387,