1
0
mirror of https://github.com/amix/vimrc synced 2025-06-16 01:25:00 +08:00

Updated plugins

This commit is contained in:
Amir Salihefendic
2018-09-24 21:40:17 -03:00
parent 6bd9eda8c3
commit a6b64938eb
199 changed files with 2897 additions and 980 deletions

View File

@ -2,7 +2,7 @@
" Filename: autoload/lightline.vim
" Author: itchyny
" License: MIT License
" Last Change: 2018/06/22 08:50:00.
" Last Change: 2018/09/17 12:00:00.
" =============================================================================
let s:save_cpo = &cpo
@ -343,9 +343,9 @@ function! s:convert(name, index) abort
let type = get(s:lightline.component_type, a:name, a:index)
let is_raw = get(s:lightline.component_raw, a:name) || type ==# 'raw'
return filter(s:map(s:evaluate_expand(s:lightline.component_expand[a:name]),
\ '[v:val, 1 + ' . is_raw . ', v:key == 1 && ' . (type !=# 'raw') . ' ? "' . type . '" : "' . a:index . '"]'), 'v:val[0] != []')
\ '[v:val, 1 + ' . is_raw . ', v:key == 1 && ' . (type !=# 'raw') . ' ? "' . type . '" : "' . a:index . '", "' . a:index . '"]'), 'v:val[0] != []')
else
return [[[a:name], 0, a:index]]
return [[[a:name], 0, a:index, a:index]]
endif
endfunction
@ -375,18 +375,30 @@ function! s:expand(components) abort
let components = []
let expanded = []
let indices = []
let prevtype = ''
let previndex = -1
let xs = s:flatten_twice(s:map(deepcopy(a:components), 'map(v:val, "s:convert(v:val, ''" . v:key . "'')")'))
for [component, expand, index] in xs
if previndex != index
call add(indices, index)
for [component, expand, type, index] in xs
if prevtype !=# type
for i in range(previndex + 1, max([previndex, index - 1]))
call add(indices, string(i))
call add(components, [])
call add(expanded, [])
endfor
call add(indices, type)
call add(components, [])
call add(expanded, [])
endif
call extend(components[-1], component)
call extend(expanded[-1], repeat([expand], len(component)))
let prevtype = type
let previndex = index
endfor
for i in range(previndex + 1, max([previndex, len(a:components) - 1]))
call add(indices, string(i))
call add(components, [])
call add(expanded, [])
endfor
call add(indices, string(len(a:components)))
return [components, expanded, indices]
endfunction

View File

@ -2,7 +2,7 @@
" Filename: autoload/lightline/colorscheme.vim
" Author: itchyny
" License: MIT License
" Last Change: 2017/11/29 12:54:05.
" Last Change: 2018/09/01 22:48:24.
" =============================================================================
let s:save_cpo = &cpo
@ -224,7 +224,7 @@ function! lightline#colorscheme#flatten(p) abort
return a:p
endfunction
if has('gui_running')
if has('gui_running') || (has('termguicolors') && &termguicolors)
function! lightline#colorscheme#background() abort
return &background
endfunction