mirror of
https://github.com/vim-airline/vim-airline.git
synced 2026-10-08 04:54:32 +08:00
reduce pollution of global scope variables
This commit is contained in:
1 parent
ee19bf8825
commit
494d15232c
4 files changed
+13
-12
No files matched your search
@@ -1,13 +1,11 @@
|
||||
" MIT License. Copyright (c) 2013 Bailey Ling.
|
||||
" vim: ts=2 sts=2 sw=2 fdm=indent
|
||||
" vim: et ts=2 sts=2 sw=2
|
||||
|
||||
if !exists('g:airline#extensions#csv#column_display')
|
||||
let g:airline#extensions#csv#column_display = 'Number'
|
||||
endif
|
||||
let s:column_display = get(g:, 'airline#extensions#csv#column_display', 'Number')
|
||||
|
||||
function! airline#extensions#csv#get_column()
|
||||
if exists('*CSV_WCol')
|
||||
if g:airline#extensions#csv#column_display ==# 'Name'
|
||||
if s:column_display ==# 'Name'
|
||||
return '['.CSV_WCol('Name').CSV_WCol().']'
|
||||
else
|
||||
return '['.CSV_WCol().']'
|
||||
|
||||
Reference in new issue
Block a user