if exists("b:is_sh")
unlet b:is_sh
endif
- elseif name =~ '\<sh\>'
+ elseif name =~ '\<sh\>' || name =~ '\<dash\>'
+ # Ubuntu links "sh" to "dash", thus it is expected to work the same way
b:is_sh = 1
if exists("b:is_kornshell")
unlet b:is_kornshell
name = 'wish'
endif
- # Bourne-like shell scripts: bash bash2 ksh ksh93 sh
- if name =~ '^\(bash\d*\|\|ksh\d*\|sh\)\>'
+ # Bourne-like shell scripts: bash bash2 dash ksh ksh93 sh
+ if name =~ '^\(bash\d*\|dash\|ksh\d*\|sh\)\>'
call dist#ft#SetFileTypeSH(line1)
# csh scripts
\ ['__libc_start_main and something']],
\ 'clojure': [['#!/path/clojure']],
\ 'scala': [['#!/path/scala']],
+ \ 'sh': [['#!/path/sh'],
+ \ ['#!/path/bash'],
+ \ ['#!/path/bash2'],
+ \ ['#!/path/dash'],
+ \ ['#!/path/ksh'],
+ \ ['#!/path/ksh93']],
+ \ 'csh': [['#!/path/csh']],
\ 'tcsh': [['#!/path/tcsh']],
\ 'zsh': [['#!/path/zsh']],
\ 'tcl': [['#!/path/tclsh'],