Merge branch 'autocmd'
This commit is contained in:
commit
d4e13ca89c
@ -113,6 +113,9 @@ function! s:HandleExit(job) abort
|
|||||||
call ale#statusline#Update(l:buffer, g:ale_buffer_loclist_map[l:buffer])
|
call ale#statusline#Update(l:buffer, g:ale_buffer_loclist_map[l:buffer])
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
" Call user autocommands. This allows users to hook into ALE's lint cycle.
|
||||||
|
doautocmd User ALELint
|
||||||
|
|
||||||
" Mark line 200, column 17 with a squiggly line or something
|
" Mark line 200, column 17 with a squiggly line or something
|
||||||
" matchadd('ALEError', '\%200l\%17v')
|
" matchadd('ALEError', '\%200l\%17v')
|
||||||
endfunction
|
endfunction
|
||||||
|
10
doc/ale.txt
10
doc/ale.txt
@ -605,7 +605,7 @@ ale#statusline#Status() *ale#statusline#Status()*
|
|||||||
Return a formatted string that can be added to the statusline.
|
Return a formatted string that can be added to the statusline.
|
||||||
The output's format is defined in |`g:ale_statusline_format`|.
|
The output's format is defined in |`g:ale_statusline_format`|.
|
||||||
To enable it, the following should be present in your |statusline| settings: >
|
To enable it, the following should be present in your |statusline| settings: >
|
||||||
%{ale#statusline#status()}
|
%{ale#statusline#Status()}
|
||||||
|
|
||||||
|
|
||||||
g:ale#util#stdin_wrapper *g:ale#util#stdin_wrapper*
|
g:ale#util#stdin_wrapper *g:ale#util#stdin_wrapper*
|
||||||
@ -613,6 +613,14 @@ g:ale#util#stdin_wrapper *g:ale#util#stdin_wrapper*
|
|||||||
which cannot accept input via stdin. See |ale#linter#Define()| for more.
|
which cannot accept input via stdin. See |ale#linter#Define()| for more.
|
||||||
|
|
||||||
|
|
||||||
|
ALELint *ALELint*
|
||||||
|
This |User| autocommand is triggered by ALE every time it completes a lint
|
||||||
|
operation. It can be used to update statuslines, send notifications, or
|
||||||
|
complete any other operation that needs to be done after a lint run.
|
||||||
|
It can be used simply:
|
||||||
|
autocmd User ALELint echom "ALE run!"
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
6. Special Thanks *ale-special-thanks*
|
6. Special Thanks *ale-special-thanks*
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user