summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorw0rp <devw0rp@gmail.com>2017-06-14 17:59:13 +0100
committerw0rp <devw0rp@gmail.com>2017-06-14 17:59:13 +0100
commitf814be45b19ae87c5931e72f67869c1fcdb35c24 (patch)
tree1a732620dfa05d7d6343ca68ea79641d5ad0876e /doc
parentc2258e36844a2b2b414c95bbe26decd377fca581 (diff)
downloadale-f814be45b19ae87c5931e72f67869c1fcdb35c24.zip
Fix #536 - Implement linter problem type re-mapping
Diffstat (limited to 'doc')
-rw-r--r--doc/ale.txt29
1 files changed, 29 insertions, 0 deletions
diff --git a/doc/ale.txt b/doc/ale.txt
index e15f5a0f..8c6ecf9d 100644
--- a/doc/ale.txt
+++ b/doc/ale.txt
@@ -745,6 +745,35 @@ g:ale_sign_warning *g:ale_sign_warning*
The sign for warnings in the sign gutter.
+g:ale_type_map *g:ale_type_map*
+ *b:ale_type_map*
+ Type: |Dictionary|
+ Default: `{}`
+
+ This option can be set re-map problem types for linters. Each key in
+ the |Dictionary| should be the name of a linter, and each value must be
+ a |Dictionary| mapping error types from one type to another. The
+ following types are supported:
+
+ `'E'` - `{'type': 'E'}`
+ `'ES'` - `{'type': 'E', 'sub_type': 'style'}`
+ `'W'` - `{'type': 'W'}`
+ `'WS'` - `{'type': 'W', 'sub_type': 'style'}`
+ `'I'` - `{'type': 'I'}`
+
+ For example, if you want to turn flake8 errors into warnings, you can do
+ the following: >
+
+ let g:ale_type_map = {'flake8', {'ES': 'WS', 'E': 'W'}}
+<
+ If you wanted to turn style errors and warnings into regular errors and
+ warnings, you can use the following: >
+
+ let g:ale_type_map = {'flake8', {'ES': 'E', 'WS': 'W'}}
+<
+ Type maps can be set per-buffer with `b:ale_type_map`.
+
+
g:ale_warn_about_trailing_whitespace *g:ale_warn_about_trailing_whitespace*
b:ale_warn_about_trailing_whitespace *b:ale_warn_about_trailing_whitespace*