Explain how to use the airline extension better

This commit is contained in:
w0rp 2017-06-25 20:01:46 +01:00
parent a9b29fef28
commit 7d73a1602b
1 changed files with 12 additions and 7 deletions

View File

@ -298,14 +298,19 @@ highlight clear ALEWarningSign
### 5.iv. How can I show errors or warnings in my statusline? ### 5.iv. How can I show errors or warnings in my statusline?
[vim-airline](https://github.com/vim-airline/vim-airline) integrates with [vim-airline](https://github.com/vim-airline/vim-airline) integrates with ALE
ALE for displaying error information in the status bar. If you want to see for displaying error information in the status bar. If you want to see the
the status for ALE in a nice format, it is recommended to use vim-airline status for ALE in a nice format, it is recommended to use vim-airline with ALE.
with ALE. The airline extension can be enabled by adding the following to your vimrc:
ALE offers the ability to show some information in statuslines with no extra ```vim
plugins. ALE provides a function for getting a summary with the number of " Set this. Airline will handle the rest.
problems detected, and you can implement your own function for your statusline. let g:airline#extensions#ale#enabled = 1
```
If you don't want to use vim-airline, you can implement your own statusline
function without adding any other plugins. ALE provides a function for counting
the number of problems for this purpose, named `ale#statusline#Count`.
Say you want to display all errors as one figure, and all non-errors as another Say you want to display all errors as one figure, and all non-errors as another
figure. You can do the following: figure. You can do the following: