Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Sep 20, 2023. It is now read-only.

Commit 77c1251

Browse files
committed
Bashate: cleanup.
1 parent d155904 commit 77c1251

1 file changed

Lines changed: 12 additions & 7 deletions

File tree

syntax_checkers/sh/bashate.vim

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,6 @@
11
"============================================================================
22
"File: bashate.vim
33
"Description: Bash script style checking plugin for syntastic.vim
4-
"Notes: bashate is a pep8 equivalent for bash scripts
5-
" Can be downloaded from:
6-
" https://pypi.python.org/pypi/bashate or
7-
" https://github.com/openstack-dev/bashate
84
"License: This program is free software. It comes without any warranty,
95
" to the extent permitted by applicable law. You can redistribute
106
" it and/or modify it under the terms of the Do What The Fuck You
@@ -25,12 +21,21 @@ function! SyntaxCheckers_sh_bashate_GetLocList() dict
2521
let makeprg = self.makeprgBuild({})
2622

2723
let errorformat =
28-
\ '%EE%n: %m: %.%#,%Z - %f : L%l'
24+
\ '%EE%n: %m,' .
25+
\ '%Z - %f: L%l,' .
26+
\ '%-G%.%#'
2927

30-
return SyntasticMake({
28+
let loclist = SyntasticMake({
3129
\ 'makeprg': makeprg,
3230
\ 'errorformat': errorformat,
33-
\ 'subtype': 'Style' })
31+
\ 'subtype': 'Style',
32+
\ 'returns': [0, 1] })
33+
34+
for e in loclist
35+
let e['text'] = substitute(e['text'], "\\m: '.*", '', '')
36+
endfor
37+
38+
return loclist
3439
endfunction
3540

3641
call g:SyntasticRegistry.CreateAndRegisterChecker({

0 commit comments

Comments
 (0)