diff options
author | w0rp <devw0rp@gmail.com> | 2018-07-15 20:57:51 +0100 |
---|---|---|
committer | w0rp <devw0rp@gmail.com> | 2018-07-15 21:01:00 +0100 |
commit | d3ed1e52ba33375c445353a0395b0caf9bd662f6 (patch) | |
tree | 7993f8c42807fb01b6fc25bb3a4a9fdf0d39fae5 /autoload | |
parent | 72f002de941fb28bc454ad6417de63690ad54233 (diff) | |
download | ale-d3ed1e52ba33375c445353a0395b0caf9bd662f6.zip |
Fix #1687 - Parse highlights when verbose > 0
Diffstat (limited to 'autoload')
-rw-r--r-- | autoload/ale/sign.vim | 30 |
1 files changed, 14 insertions, 16 deletions
diff --git a/autoload/ale/sign.vim b/autoload/ale/sign.vim index 31663721..a0dde359 100644 --- a/autoload/ale/sign.vim +++ b/autoload/ale/sign.vim @@ -45,25 +45,23 @@ if !hlexists('ALESignColumnWithErrors') highlight link ALESignColumnWithErrors error endif -if !hlexists('ALESignColumnWithoutErrors') - function! s:SetSignColumnWithoutErrorsHighlight() abort - redir => l:output - silent highlight SignColumn - redir end - - let l:highlight_syntax = join(split(l:output)[2:]) +function! ale#sign#SetUpDefaultColumnWithoutErrorsHighlight() abort + redir => l:output + 0verbose silent highlight SignColumn + redir end - let l:match = matchlist(l:highlight_syntax, '\vlinks to (.+)$') + let l:highlight_syntax = join(split(l:output)[2:]) + let l:match = matchlist(l:highlight_syntax, '\vlinks to (.+)$') - if !empty(l:match) - execute 'highlight link ALESignColumnWithoutErrors ' . l:match[1] - elseif l:highlight_syntax isnot# 'cleared' - execute 'highlight ALESignColumnWithoutErrors ' . l:highlight_syntax - endif - endfunction + if !empty(l:match) + execute 'highlight link ALESignColumnWithoutErrors ' . l:match[1] + elseif l:highlight_syntax isnot# 'cleared' + execute 'highlight ALESignColumnWithoutErrors ' . l:highlight_syntax + endif +endfunction - call s:SetSignColumnWithoutErrorsHighlight() - delfunction s:SetSignColumnWithoutErrorsHighlight +if !hlexists('ALESignColumnWithoutErrors') + call ale#sign#SetUpDefaultColumnWithoutErrorsHighlight() endif " Signs show up on the left for error markers. |