Fixed shebang detection for multiple buffers

This commit is contained in:
Jeremy Cantrell 2010-06-24 12:43:52 +08:00 committed by Martin Grenfell
parent f2b98a8426
commit 5f775a452c

View File

@ -15,7 +15,7 @@ endif
let loaded_sh_syntax_checker = 1
function! GetShell()
let shebang = getbufline(bufname('.'), 1)[0]
let shebang = getbufline(bufnr('%'), 1)[0]
if len(shebang) > 0
if match(shebang, 'bash') >= 0
return 'bash'