]> git.ipfire.org Git - thirdparty/vim.git/commitdiff
patch 8.2.5110: icon filetype not recognized from the first line v8.2.5110
authorBram Moolenaar <Bram@vim.org>
Thu, 16 Jun 2022 12:27:18 +0000 (13:27 +0100)
committerBram Moolenaar <Bram@vim.org>
Thu, 16 Jun 2022 12:27:18 +0000 (13:27 +0100)
Problem:    Icon filetype not recognized from the first line.
Solution:   Add a check for the first line. (Doug Kearns)

runtime/autoload/dist/script.vim
src/testdir/test_filetype.vim
src/version.c

index b926f31566a3c7a57dbea28d7ea1d39dc3e3df54..86070a0af9077eb663cf953dc90f7f023be864a3 100644 (file)
@@ -189,6 +189,10 @@ def DetectFromHashBang(firstline: string)
   elseif name =~ 'gforth\>'
     set ft=forth
 
+    # Icon
+  elseif name =~ 'icon\>'
+    set ft=icon
+
   endif
 enddef
 
index 5f10aacac41dba58bd557c07605b1e3cb53acbf7..6c2343b1e22c99ac87f6e253f6917b69a584b21a 100644 (file)
@@ -718,6 +718,7 @@ let s:script_checks = {
       \ 'routeros': [['#!/path/rsc']],
       \ 'fish': [['#!/path/fish']],
       \ 'forth': [['#!/path/gforth']],
+      \ 'icon': [['#!/path/icon']],
       \ }
 
 " Various forms of "env" optional arguments.
index e581f1a02c7ba93fd0fac57d50014f20e92da41e..1f38480d0de9a036d063f7b247a1790488cb5119 100644 (file)
@@ -734,6 +734,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    5110,
 /**/
     5109,
 /**/