mirror of
https://github.com/vim-airline/vim-airline.git
synced 2024-11-26 18:31:02 +08:00
Merge branch 'master' into dev
This commit is contained in:
commit
aabb85ddc2
|
@ -204,7 +204,10 @@ function! airline#extensions#load()
|
|||
if !get(g:, 'airline#extensions#'.name.'#enabled', 1)
|
||||
continue
|
||||
endif
|
||||
try
|
||||
call airline#extensions#{name}#init(s:ext)
|
||||
catch
|
||||
endtry
|
||||
endif
|
||||
endfor
|
||||
endfunction
|
||||
|
|
|
@ -1,14 +1,18 @@
|
|||
" MIT License. Copyright (c) 2013 Bailey Ling.
|
||||
" vim: et ts=2 sts=2 sw=2
|
||||
|
||||
let s:empty_message = get(g:, 'airline#extensions#branch#empty_message',
|
||||
\ get(g:, 'airline_branch_empty_message', ''))
|
||||
let s:symbol = get(g:, 'airline#extensions#branch#symbol', g:airline_symbols.branch)
|
||||
|
||||
let s:has_fugitive = exists('*fugitive#head')
|
||||
let s:has_fugitive_detect = exists('*fugitive#detect')
|
||||
let s:has_lawrencium = exists('*lawrencium#statusline')
|
||||
|
||||
if !s:has_fugitive && !s:has_lawrencium
|
||||
finish
|
||||
endif
|
||||
|
||||
let s:empty_message = get(g:, 'airline#extensions#branch#empty_message',
|
||||
\ get(g:, 'airline_branch_empty_message', ''))
|
||||
let s:symbol = get(g:, 'airline#extensions#branch#symbol', g:airline_symbols.branch)
|
||||
|
||||
function! airline#extensions#branch#get_head()
|
||||
let head = ''
|
||||
|
||||
|
|
|
@ -1,6 +1,10 @@
|
|||
" MIT License. Copyright (c) 2013 Bailey Ling.
|
||||
" vim: et ts=2 sts=2 sw=2
|
||||
|
||||
if !exists('*bufferline#get_status_string')
|
||||
finish
|
||||
endif
|
||||
|
||||
let s:overwrite = get(g:, 'airline#extensions#bufferline#overwrite_variables', 1)
|
||||
|
||||
function! airline#extensions#bufferline#init(ext)
|
||||
|
|
|
@ -1,6 +1,10 @@
|
|||
" MIT License. Copyright (c) 2013 Bailey Ling.
|
||||
" vim: et ts=2 sts=2 sw=2
|
||||
|
||||
if !get(g:, 'command_t_loaded', 0)
|
||||
finish
|
||||
endif
|
||||
|
||||
function! airline#extensions#commandt#apply(...)
|
||||
if bufname('%') ==# 'GoToFile'
|
||||
call airline#extensions#apply_left_override('CommandT', '')
|
||||
|
|
|
@ -1,6 +1,10 @@
|
|||
" MIT License. Copyright (c) 2013 Bailey Ling.
|
||||
" vim: et ts=2 sts=2 sw=2
|
||||
|
||||
if !get(g:, 'loaded_csv', 0)
|
||||
finish
|
||||
endif
|
||||
|
||||
let s:column_display = get(g:, 'airline#extensions#csv#column_display', 'Number')
|
||||
|
||||
function! airline#extensions#csv#get_column()
|
||||
|
|
|
@ -1,6 +1,10 @@
|
|||
" MIT License. Copyright (c) 2013 Bailey Ling.
|
||||
" vim: et ts=2 sts=2 sw=2
|
||||
|
||||
if !get(g:, 'loaded_ctrlp', 0)
|
||||
finish
|
||||
endif
|
||||
|
||||
let s:color_template = get(g:, 'airline#extensions#ctrlp#color_template', 'insert')
|
||||
|
||||
function! airline#extensions#ctrlp#generate_color_map(dark, light, white)
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
" MIT License. Copyright (c) 2013 Bailey Ling.
|
||||
" vim: et ts=2 sts=2 sw=2
|
||||
|
||||
" we don't actually want this loaded :P
|
||||
finish
|
||||
|
||||
" Extension specific variables can be defined the usual fashion.
|
||||
if !exists('g:airline#extensions#example#number_of_cats')
|
||||
let g:airline#extensions#example#number_of_cats = 42
|
||||
|
|
|
@ -1,6 +1,10 @@
|
|||
" MIT License. Copyright (c) 2013 Bailey Ling.
|
||||
" vim: et ts=2 sts=2 sw=2
|
||||
|
||||
if !get(g:, 'loaded_signify', 0) && !get(g:, 'loaded_gitgutter', 0)
|
||||
finish
|
||||
endif
|
||||
|
||||
let s:non_zero_only = get(g:, 'airline#extensions#hunks#non_zero_only', 0)
|
||||
let s:hunk_symbols = get(g:, 'airline#extensions#hunks#hunk_symbols', ['+', '~', '-'])
|
||||
|
||||
|
|
|
@ -1,6 +1,10 @@
|
|||
" MIT License. Copyright (c) 2013 Bailey Ling.
|
||||
" vim: et ts=2 sts=2 sw=2
|
||||
|
||||
if !exists(':SyntasticCheck')
|
||||
finish
|
||||
endif
|
||||
|
||||
function! airline#extensions#syntastic#get_warnings()
|
||||
let errors = SyntasticStatuslineFlag()
|
||||
if strlen(errors) > 0
|
||||
|
|
|
@ -1,6 +1,10 @@
|
|||
" MIT License. Copyright (c) 2013 Bailey Ling.
|
||||
" vim: et ts=2 sts=2 sw=2
|
||||
|
||||
if !exists(':TagbarToggle')
|
||||
finish
|
||||
endif
|
||||
|
||||
let s:flags = get(g:, 'airline#extensions#tagbar#flags', '')
|
||||
|
||||
" Arguments: current, sort, fname
|
||||
|
|
|
@ -1,6 +1,10 @@
|
|||
" MIT License. Copyright (c) 2013 Bailey Ling.
|
||||
" vim: et ts=2 sts=2 sw=2
|
||||
|
||||
if !exists(':UndotreeToggle')
|
||||
finish
|
||||
endif
|
||||
|
||||
function! airline#extensions#undotree#apply(...)
|
||||
if exists('t:undotree')
|
||||
if &ft == 'undotree'
|
||||
|
|
|
@ -1,6 +1,10 @@
|
|||
" MIT License. Copyright (c) 2013 Bailey Ling.
|
||||
" vim: et ts=2 sts=2 sw=2
|
||||
|
||||
if !get(g:, 'loaded_unite', 0)
|
||||
finish
|
||||
endif
|
||||
|
||||
function! airline#extensions#unite#apply(...)
|
||||
if &ft == 'unite'
|
||||
call a:1.add_section('airline_a', ' Unite ')
|
||||
|
|
|
@ -1,6 +1,10 @@
|
|||
" MIT License. Copyright (c) 2013 Bailey Ling.
|
||||
" vim: et ts=2 sts=2 sw=2
|
||||
|
||||
if !get(g:, 'virtualenv_loaded', 0)
|
||||
finish
|
||||
endif
|
||||
|
||||
function! airline#extensions#virtualenv#init(ext)
|
||||
call a:ext.add_statusline_func('airline#extensions#virtualenv#apply')
|
||||
endfunction
|
||||
|
|
Loading…
Reference in New Issue
Block a user