summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorw0rp <w0rp@users.noreply.github.com>2016-10-30 09:20:02 +0000
committerGitHub <noreply@github.com>2016-10-30 09:20:02 +0000
commite9bbbbdf3ee08b6f0bc681f0e16caf08106a6a0e (patch)
treeca6f8763bec7eeed7f6090175115af06d67cdb88
parentc8821fc0495d1d75cb3d716d73c4c28877e3513a (diff)
parent86cc2aab7107c2dc75bea568e3d9a91b46b1a295 (diff)
downloadale-e9bbbbdf3ee08b6f0bc681f0e16caf08106a6a0e.zip
Merge pull request #151 from keith/ks/pylint
Add pylint formatter
-rw-r--r--ale_linters/python/pylint.vim9
-rw-r--r--autoload/ale/handlers.vim2
2 files changed, 10 insertions, 1 deletions
diff --git a/ale_linters/python/pylint.vim b/ale_linters/python/pylint.vim
new file mode 100644
index 00000000..9e6093c7
--- /dev/null
+++ b/ale_linters/python/pylint.vim
@@ -0,0 +1,9 @@
+" Author: keith <k@keith.so>
+" Description: pylint for python files
+
+call ale#linter#Define('python', {
+\ 'name': 'pylint',
+\ 'executable': 'pylint',
+\ 'command': g:ale#util#stdin_wrapper . ' .py pylint --output-format text --msg-template="{path}:{line}:{column}: {msg_id} {msg}" --reports n',
+\ 'callback': 'ale#handlers#HandlePEP8Format',
+\})
diff --git a/autoload/ale/handlers.vim b/autoload/ale/handlers.vim
index 9ac0c192..177cdc43 100644
--- a/autoload/ale/handlers.vim
+++ b/autoload/ale/handlers.vim
@@ -4,7 +4,7 @@ scriptencoding utf-8
" linter which outputs warnings and errors in a format accepted by one of
" these functions can simply use one of these pre-defined error handlers.
-let s:path_pattern = '[a-zA-Z]\?\\\?:\?[[:alnum:]/\.-]\+'
+let s:path_pattern = '[a-zA-Z]\?\\\?:\?[[:alnum:]/\.\-_]\+'
function! s:HandleUnixFormat(buffer, lines, type) abort
" Matches patterns line the following: