patch 9.1.2007: filetype: bpftrace hashbang lines are not recognized

Commit: 
https://github.com/vim/vim/commit/f2814754c0cd39875adcadffcb73206a83a46099
Author: Stanislaw Gruszka <[email protected]>
Date:   Mon Dec 22 18:17:36 2025 +0000

    patch 9.1.2007: filetype: bpftrace hashbang lines are not recognized
    
    Problem:    bpftrace files are not recognized from the hashbang line.
    Solution:   Add a hashbang check (Stanislaw Gruszka)
    
    closes: #18992
    
    Signed-off-by: Stanislaw Gruszka <[email protected]>
    Signed-off-by: Christian Brabandt <[email protected]>

diff --git a/runtime/autoload/dist/script.vim b/runtime/autoload/dist/script.vim
index 5fb45ccc5..de168f0c0 100644
--- a/runtime/autoload/dist/script.vim
+++ b/runtime/autoload/dist/script.vim
@@ -4,7 +4,7 @@ vim9script
 # Invoked from "scripts.vim" in 'runtimepath'
 #
 # Maintainer:  The Vim Project <https://github.com/vim/vim>
-# Last Change: 2025 Aug 09
+# Last Change: 2025 Dec 22
 # Former Maintainer:   Bram Moolenaar <[email protected]>
 
 export def DetectFiletype()
@@ -233,6 +233,10 @@ export def Exe2filetype(name: string, line1: string): 
string
   elseif name =~ '^execlineb\>'
     return 'execline'
 
+    # Bpftrace
+  elseif name =~ '^bpftrace\>'
+    return 'bpftrace'
+
     # Vim
   elseif name =~ '^vim\>'
     return 'vim'
diff --git a/src/testdir/test_filetype.vim b/src/testdir/test_filetype.vim
index 65f8bae32..6392f6996 100644
--- a/src/testdir/test_filetype.vim
+++ b/src/testdir/test_filetype.vim
@@ -1095,6 +1095,7 @@ def s:GetScriptChecks(): dict<list<list<string>>>
             ['#!/path/regina']],
     janet:  [['#!/path/janet']],
     dart:   [['#!/path/dart']],
+    bpftrace:  [['#!/path/bpftrace']],
     vim:    [['#!/path/vim']],
   }
 enddef
diff --git a/src/version.c b/src/version.c
index 12dfb27af..ce81ba547 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 */
+/**/
+    2007,
 /**/
     2006,
 /**/

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion visit 
https://groups.google.com/d/msgid/vim_dev/E1vXkfX-00AVNO-GX%40256bit.org.

Raspunde prin e-mail lui