vim-patch:9.0.1807: runtime: crystal scripts not recognised (#24949)

Problem:  runtime: crystal scripts not recognised
Solution: Filetype detect Crystal scripts by shebang line

closes: vim/vim#12935

9b73902dbe

Co-authored-by: Doug Kearns <dougkearns@gmail.com>
This commit is contained in:
zeertzjq 2023-08-31 04:38:28 +08:00 committed by GitHub
parent 497cf996eb
commit 6463116818
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 0 deletions

View File

@ -1636,6 +1636,7 @@ local patterns_hashbang = {
['icon\\>'] = { 'icon', { vim_regex = true } },
guile = 'scheme',
['nix%-shell'] = 'nix',
['crystal\\>'] = { 'crystal', { vim_regex = true } },
}
---@private

View File

@ -855,6 +855,7 @@ let s:script_checks = {
\ 'fish': [['#!/path/fish']],
\ 'forth': [['#!/path/gforth']],
\ 'icon': [['#!/path/icon']],
\ 'crystal': [['#!/path/crystal']],
\ }
" Various forms of "env" optional arguments.