summaryrefslogtreecommitdiff
path: root/ale_linters/sh
diff options
context:
space:
mode:
authorw0rp <devw0rp@gmail.com>2017-04-03 22:51:39 +0100
committerw0rp <devw0rp@gmail.com>2017-04-03 22:51:39 +0100
commit4fc8452838253a59fabc58ba48ea7a6425261edb (patch)
tree80a11f6cfd507aa5a43afbbd657e3a8b76bbce14 /ale_linters/sh
parent85d86620f7459fd7caf14e4b8be2880006b36881 (diff)
downloadale-4fc8452838253a59fabc58ba48ea7a6425261edb.zip
#447 Support zsh in the shell linter
Diffstat (limited to 'ale_linters/sh')
-rw-r--r--ale_linters/sh/shell.vim6
1 files changed, 3 insertions, 3 deletions
diff --git a/ale_linters/sh/shell.vim b/ale_linters/sh/shell.vim
index 7ab98fd6..412aa8bb 100644
--- a/ale_linters/sh/shell.vim
+++ b/ale_linters/sh/shell.vim
@@ -38,7 +38,7 @@ function! ale_linters#sh#shell#Handle(buffer, lines) abort
"
" bash: line 13: syntax error near unexpected token `d'
" sh: 11: Syntax error: "(" unexpected
- let l:pattern = '^[^:]\+: \%(\w\+ \|\)\(\d\+\): \(.\+\)'
+ let l:pattern = '\v(line |: ?)(\d+): (.+)$'
let l:output = []
for l:line in a:lines
@@ -48,8 +48,8 @@ function! ale_linters#sh#shell#Handle(buffer, lines) abort
continue
endif
- let l:line = l:match[1] + 0
- let l:text = l:match[2]
+ let l:line = l:match[2] + 0
+ let l:text = l:match[3]
let l:type = 'E'
call add(l:output, {