mirror of
https://github.com/amix/vimrc
synced 2025-07-12 06:05:01 +08:00
updated plugins and added eslint goodies
This commit is contained in:
@ -1,9 +1,9 @@
|
||||
" MIT License. Copyright (c) 2013-2015 Bailey Ling.
|
||||
" MIT License. Copyright (c) 2013-2016 Bailey Ling.
|
||||
" vim: et ts=2 sts=2 sw=2
|
||||
|
||||
let g:airline_statusline_funcrefs = get(g:, 'airline_statusline_funcrefs', [])
|
||||
|
||||
let s:sections = ['a','b','c','gutter','x','y','z','warning']
|
||||
let s:sections = ['a','b','c','gutter','x','y','z', 'error', 'warning']
|
||||
let s:inactive_funcrefs = []
|
||||
|
||||
function! airline#add_statusline_func(name)
|
||||
@ -71,6 +71,7 @@ endfunction
|
||||
|
||||
function! airline#switch_matching_theme()
|
||||
if exists('g:colors_name')
|
||||
let existing = g:airline_theme
|
||||
try
|
||||
let palette = g:airline#themes#{g:colors_name}#palette
|
||||
call airline#switch_theme(g:colors_name)
|
||||
@ -78,7 +79,12 @@ function! airline#switch_matching_theme()
|
||||
catch
|
||||
for map in items(g:airline_theme_map)
|
||||
if match(g:colors_name, map[0]) > -1
|
||||
call airline#switch_theme(map[1])
|
||||
try
|
||||
let palette = g:airline#themes#{map[1]}#palette
|
||||
call airline#switch_theme(map[1])
|
||||
catch
|
||||
call airline#switch_theme(existing)
|
||||
endtry
|
||||
return 1
|
||||
endif
|
||||
endfor
|
||||
@ -88,6 +94,9 @@ function! airline#switch_matching_theme()
|
||||
endfunction
|
||||
|
||||
function! airline#update_statusline()
|
||||
if airline#util#getwinvar(winnr(), 'airline_disabled', 0)
|
||||
return
|
||||
endif
|
||||
for nr in filter(range(1, winnr('$')), 'v:val != winnr()')
|
||||
if airline#util#getwinvar(nr, 'airline_disabled', 0)
|
||||
continue
|
||||
|
Reference in New Issue
Block a user