update readme, help; add faq, sample symbols
This commit is contained in:
parent
05ee8c0fc7
commit
1f15d5dbc1
29
README.md
29
README.md
|
@ -1,34 +1,35 @@
|
|||
# vim-airline
|
||||
|
||||
lean & mean statusline for vim
|
||||
lean & mean statusline for vim that's light as air
|
||||
|
||||
# rationale
|
||||
|
||||
there's already [powerline](https://github.com/Lokaltog/powerline), why yet another statusline?
|
||||
there's already [powerline][b], why yet another statusline?
|
||||
|
||||
* it's standard vimscript, no python needed
|
||||
* it's small. i want the entire plugin to be less than 200 lines as a rule
|
||||
* gets you 90% of the way there: in addition to all the standard goodies, supports [fugitve](https://github.com/tpope/vim-fugitive) and [syntastic](https://github.com/scrooloose/syntastic)
|
||||
* gets you 90% of the way there: in addition to all the standard goodies, supports [fugitive](https://github.com/tpope/vim-fugitive) and [syntastic](https://github.com/scrooloose/syntastic)
|
||||
* integration with [vim-bufferline](https://github.com/bling/vim-bufferline)
|
||||
* looks good with regular fonts, with support to use powerline font glyths
|
||||
* it's fast to load. since it's so small, it only takes 0.5ms to load. by comparison, powerline needs 60ms on the same machine.
|
||||
|
||||
# why's it called airline?
|
||||
|
||||
i wrote this on an airplane, and since it's light as air it turned out to be a good name :-)
|
||||
i wrote this on an airplane, and since it's light as air it turned out to be a good name. thanks for flying vim!
|
||||
|
||||
# configuration
|
||||
|
||||
there are a couple configuration values available:
|
||||
`:help airline`
|
||||
|
||||
* `g:airline_left_sep` the seperator used on the left side
|
||||
* `g:airline_right_sep` the seperator used on the right side
|
||||
* `g:airline_enable_fugitive` enable/disable fugitive integration
|
||||
* `g:airline_enable_syntastic` enable/disable syntastic integration
|
||||
* `g:airline_theme` change the theme, currently only `default` is available
|
||||
* `g:airline_powerline_fonts` enable/disable usage of patched powerline font symbols
|
||||
# faq
|
||||
|
||||
# demo
|
||||
1. the powerline font symbols are not showing up
|
||||
* the older deprecated [vim-powerline][a] uses different codes compared to the newer [powerline][b].
|
||||
* you can grab prepatched fonts at [powerline-fonts][c], or you can manually set the relevant `g:` variables
|
||||
2. leaving insert mode does not update the statusline
|
||||
* this has been reproducible on older versions of vim, please use a newer version of vim
|
||||
|
||||
# screenshots
|
||||
|
||||
## regular font
|
||||
|
||||
|
@ -45,3 +46,7 @@ contributions and pull requests are welcome.
|
|||
# license
|
||||
|
||||
`:h license`
|
||||
|
||||
[a]: https://github.com/Lokaltog/vim-powerline
|
||||
[b]: https://github.com/Lokaltog/powerline
|
||||
[c]: https://github.com/Lokaltog/powerline-fonts
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
*airline.txt* Lean and mean statusline
|
||||
*airline.txt* Lean and mean statusline that's light as air
|
||||
|
||||
==============================================================================
|
||||
RATIONALE *airline*
|
||||
|
@ -25,7 +25,7 @@ i wrote this on an airplane, and since it's light as air it turned out to be a
|
|||
good name :-)
|
||||
|
||||
==============================================================================
|
||||
CONFIGURATION *airline-configuration*
|
||||
CONFIGURATION *airline-configuration*
|
||||
|
||||
there are a couple configuration values available (shown with their default
|
||||
values):
|
||||
|
@ -60,6 +60,32 @@ values):
|
|||
let g:airline_powerline_fonts=0
|
||||
<
|
||||
|
||||
==============================================================================
|
||||
CUSTOMIZATION *airline-customization*
|
||||
|
||||
here are some unicode symbols for customizing the left/right seperators, as
|
||||
well as the powerline font glyths
|
||||
|
||||
>
|
||||
" unicode symbols
|
||||
let g:airline_left_sep = '»'
|
||||
let g:airline_left_sep = '▶'
|
||||
let g:airline_right_sep = '«'
|
||||
let g:airline_right_sep = '◀'
|
||||
let g:airline_linecolumn_prefix = '␊ '
|
||||
let g:airline_linecolumn_prefix = ' '
|
||||
let g:airline_fugitive_prefix = '⎇ '
|
||||
|
||||
" powerline symbols
|
||||
let g:airline_left_sep = ''
|
||||
let g:airline_left_sep = ''
|
||||
let g:airline_right_sep = ''
|
||||
let g:airline_right_sep = ''
|
||||
let g:airline_fugitive_prefix = ' '
|
||||
let g:airline_readonly_symbol = ''
|
||||
let g:airline_linecolumn_prefix = ' '
|
||||
<
|
||||
|
||||
==============================================================================
|
||||
CONTRIBUTIONS *airline-contributions*
|
||||
|
||||
|
|
|
@ -1,10 +1,8 @@
|
|||
" powerline symbols:
|
||||
" some unicode symbols: ▶ » « ◀
|
||||
if !exists('g:airline_left_sep')
|
||||
let g:airline_left_sep=exists('g:airline_powerline_fonts')?"":">"
|
||||
let g:airline_left_sep = exists('g:airline_powerline_fonts')?"":">"
|
||||
endif
|
||||
if !exists('g:airline_right_sep')
|
||||
let g:airline_right_sep=exists('g:airline_powerline_fonts')?"":"<"
|
||||
let g:airline_right_sep = exists('g:airline_powerline_fonts')?"":"<"
|
||||
endif
|
||||
if !exists('g:airline_enable_fugitive')
|
||||
let g:airline_enable_fugitive = 1
|
||||
|
@ -12,10 +10,18 @@ endif
|
|||
if !exists('g:airline_enable_syntastic')
|
||||
let g:airline_enable_syntastic = 1
|
||||
endif
|
||||
let g:airline_fugitive_prefix = exists('g:airline_powerline_fonts')?' ':' '
|
||||
let g:airline_readonly_symbol = exists('g:airline_powerline_fonts')?'':'RO'
|
||||
let g:airline_linecolumn_prefix = exists('g:airline_powerline_fonts')?' ':':'
|
||||
let g:airline_theme = 'default'
|
||||
if !exists('g:airline_fugitive_prefix')
|
||||
let g:airline_fugitive_prefix = exists('g:airline_powerline_fonts')?' ':' '
|
||||
endif
|
||||
if !exists('g:airline_readonly_symbol')
|
||||
let g:airline_readonly_symbol = exists('g:airline_powerline_fonts')?'':'RO'
|
||||
endif
|
||||
if !exists('g:airline_linecolumn_prefix')
|
||||
let g:airline_linecolumn_prefix = exists('g:airline_powerline_fonts')?' ':':'
|
||||
endif
|
||||
if !exists('g:airline_theme')
|
||||
let g:airline_theme = 'default'
|
||||
endif
|
||||
|
||||
set laststatus=2
|
||||
|
||||
|
|
Loading…
Reference in New Issue