mirror of
https://github.com/neovim/neovim.git
synced 2025-10-26 12:27:24 +00:00
vim-patch:9.1.0492: filetype: Vim-script files not detected by shebang line
Problem: Vim-script files may not be recognised
Solution: Add shebang line detection (Doug Kearns)
closes: vim/vim#15012
0d4d23dac0
Co-authored-by: Doug Kearns <dougkearns@gmail.com>
This commit is contained in:
@@ -1783,6 +1783,7 @@ local patterns_hashbang = {
|
|||||||
['^janet\\>'] = { 'janet', { vim_regex = true } },
|
['^janet\\>'] = { 'janet', { vim_regex = true } },
|
||||||
['^dart\\>'] = { 'dart', { vim_regex = true } },
|
['^dart\\>'] = { 'dart', { vim_regex = true } },
|
||||||
['^execlineb\\>'] = { 'execline', { vim_regex = true } },
|
['^execlineb\\>'] = { 'execline', { vim_regex = true } },
|
||||||
|
['^vim\\>'] = { 'vim', { vim_regex = true } },
|
||||||
}
|
}
|
||||||
|
|
||||||
---@private
|
---@private
|
||||||
|
|||||||
@@ -992,6 +992,7 @@ func s:GetScriptChecks() abort
|
|||||||
\ ['#!/path/regina']],
|
\ ['#!/path/regina']],
|
||||||
\ 'janet': [['#!/path/janet']],
|
\ 'janet': [['#!/path/janet']],
|
||||||
\ 'dart': [['#!/path/dart']],
|
\ 'dart': [['#!/path/dart']],
|
||||||
|
\ 'vim': [['#!/path/vim']],
|
||||||
\ }
|
\ }
|
||||||
endfunc
|
endfunc
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user