patch 9.1.0965: filetype: sh filetype set when detecting the use of bash
Problem: filetype: sh filetype set when detecting the use of bash
Solution: when bash is detected, use 'bash' filetype instead
(Luca Saccarola)
closes: #16309
Signed-off-by: Luca Saccarola <github.e41mv@aleeas.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
committed by
Christian Brabandt
parent
0a3b9fb5c2
commit
b9b762c21f
1
runtime/autoload/dist/ft.vim
vendored
1
runtime/autoload/dist/ft.vim
vendored
@ -896,6 +896,7 @@ export def SetFileTypeSH(name: string, setft = true): string
|
||||
if exists("b:is_sh")
|
||||
unlet b:is_sh
|
||||
endif
|
||||
return SetFileTypeShell("bash", setft)
|
||||
elseif name =~ '\<sh\>' || name =~ '\<dash\>'
|
||||
# Ubuntu links "sh" to "dash", thus it is expected to work the same way
|
||||
b:is_sh = 1
|
||||
|
||||
Reference in New Issue
Block a user