Super simple vim plugin to show the list of buffers in the command bar.
TODO
autocmd BufEnter *
\ let &statusline='%{bufferline#refresh_status()}' .
\ bufferline#get_status_string('StatusLine', 'StatusLineNC')
TODO
let g:bufferline_echo = 1
In tabline (using lightline.vim)
let g:bufferline_active_buffer_left = ''
let g:bufferline_active_buffer_right = ''
let g:bufferline_show_bufnr = 0
let g:bufferline_fname_mod = ':~:.'
let g:bufferline_pathshorten = 1
let g:lightline = {
\ 'tab': {
\ 'active': ['tabnum'],
\ 'inactive': ['tabnum']
\ },
\ 'tabline': {
\ 'left': [ ['tabs'], ['bufferline'] ],
\ 'right': [ ['fileencoding'] ]
\ },
\ 'component': {
\ 'bufferline': '%{MyBufferlineRefresh()}' . bufferline#get_status_string('TabLineSel', 'LightLineLeft_tabline_tabsel_1'),
\ 'fileencoding': '%{&fenc}',
\ }
\ }
function! MyBufferlineRefresh()
call bufferline#refresh_status()
let rlen = 4*tabpagenr('$') + len(&fenc) + 8
call bufferline#trim_status_info(&columns - rlen)
return ''
endfunction
-
$ git clone https://github.com/critiqjo/vim-bufferline ~/.vim/bundle/vim-bufferline
-
NeoBundle 'critiqjo/vim-bufferline'
-
Plugin 'critiqjo/vim-bufferline'
-
Plug 'critiqjo/vim-bufferline'
The original author was Bailey Ling, who was inspired by the buftabs script.
MIT License. Copyright (c) 2013 Bailey Ling.