mirror of
https://github.com/vim-airline/vim-airline.git
synced 2025-02-12 19:17:47 +08:00
fix vint
This commit is contained in:
parent
0c8164b1b3
commit
dad2c03cf5
|
@ -71,7 +71,7 @@ function! airline#extensions#lsp#progress() abort
|
||||||
|
|
||||||
" show only most new progress
|
" show only most new progress
|
||||||
let s:lsp_progress = s:lsp_progress[0]
|
let s:lsp_progress = s:lsp_progress[0]
|
||||||
if s:lsp_progress['message'] != '' && s:lsp_progress['percentage'] != 100
|
if s:lsp_progress['message'] !=# '' && s:lsp_progress['percentage'] !=# 100
|
||||||
let percent = ''
|
let percent = ''
|
||||||
if s:lsp_progress['percentage'] >= 0
|
if s:lsp_progress['percentage'] >= 0
|
||||||
let percent = ' ' . string(s:lsp_progress['percentage']) . '%'
|
let percent = ' ' . string(s:lsp_progress['percentage']) . '%'
|
||||||
|
@ -100,5 +100,8 @@ function! airline#extensions#lsp#init(ext) abort
|
||||||
call airline#parts#define_function('lsp_error_count', 'airline#extensions#lsp#get_error')
|
call airline#parts#define_function('lsp_error_count', 'airline#extensions#lsp#get_error')
|
||||||
call airline#parts#define_function('lsp_warning_count', 'airline#extensions#lsp#get_warning')
|
call airline#parts#define_function('lsp_warning_count', 'airline#extensions#lsp#get_warning')
|
||||||
call airline#parts#define_function('lsp_progress', 'airline#extensions#lsp#progress')
|
call airline#parts#define_function('lsp_progress', 'airline#extensions#lsp#progress')
|
||||||
|
augroup airline_lsp_progress
|
||||||
|
autocmd!
|
||||||
autocmd User lsp_progress_updated call airline#extensions#lsp#update()
|
autocmd User lsp_progress_updated call airline#extensions#lsp#update()
|
||||||
|
augroup END
|
||||||
endfunction
|
endfunction
|
||||||
|
|
Loading…
Reference in New Issue
Block a user