Merge pull request #2117 from kazukazuinaina/update_ycm_extension
[add] ycm's toggle and doc
This commit is contained in:
commit
c8fe296c52
|
@ -1,8 +1,13 @@
|
|||
" MIT License. Copyright (c) 2015-2019 Evgeny Firsov et al.
|
||||
" Plugin: https://github.com/ycm-core/YouCompleteMe
|
||||
" vim: et ts=2 sts=2 sw=2
|
||||
|
||||
scriptencoding utf-8
|
||||
|
||||
if !exists('g:loaded_youcompleteme')
|
||||
finish
|
||||
endif
|
||||
|
||||
let s:spc = g:airline_symbols.space
|
||||
let s:error_symbol = get(g:, 'airline#extensions#ycm#error_symbol', 'E:')
|
||||
let s:warning_symbol = get(g:, 'airline#extensions#ycm#warning_symbol', 'W:')
|
||||
|
@ -12,8 +17,8 @@ function! airline#extensions#ycm#init(ext)
|
|||
call airline#parts#define_function('ycm_warning_count', 'airline#extensions#ycm#get_warning_count')
|
||||
endfunction
|
||||
|
||||
function! airline#extensions#ycm#get_error_count()
|
||||
if exists(':YcmDiag') && exists("*youcompleteme#GetErrorCount")
|
||||
function! airline#extensions#ycm#get_error_count() abort
|
||||
if exists("*youcompleteme#GetErrorCount")
|
||||
let cnt = youcompleteme#GetErrorCount()
|
||||
|
||||
if cnt != 0
|
||||
|
@ -25,7 +30,7 @@ function! airline#extensions#ycm#get_error_count()
|
|||
endfunction
|
||||
|
||||
function! airline#extensions#ycm#get_warning_count()
|
||||
if exists(':YcmDiag') && exists("*youcompleteme#GetWarningCount")
|
||||
if exists("*youcompleteme#GetWarningCount")
|
||||
let cnt = youcompleteme#GetWarningCount()
|
||||
|
||||
if cnt != 0
|
||||
|
|
|
@ -1517,7 +1517,7 @@ be updated automatically. Either re-enter the tab or press <F5> two times.
|
|||
\ airline#extensions#tabline#xtabline#prev_buffer(v:count) : "\<Left>"
|
||||
|
||||
------------------------------------- *airline-ycm*
|
||||
YouCompleteMe <https://github.com/Valloric/YouCompleteMe>
|
||||
YouCompleteMe <https://github.com/ycm-core/YouCompleteMe>
|
||||
|
||||
Shows number of errors and warnings in the current file detected by YCM.
|
||||
|
||||
|
|
Loading…
Reference in New Issue