add current git branch to status, thanks to the fugitive plugin

This commit is contained in:
nojhan 2012-05-09 18:35:41 +02:00
commit c854dd8c4e

2
.vimrc
View file

@ -98,7 +98,7 @@ au VimEnter * echomsg system('/usr/games/fortune vimtweets')
set laststatus=2 " always show the statusline, even when there is only one file edited
if has("statusline")
set statusline=\ %f%m%r\ [%{strlen(&ft)?&ft:'aucun'},%{strlen(&fenc)?&fenc:&enc},%{&fileformat},ts:%{&tabstop}]%=%l,%c%V\ %P
set statusline=\ %f%m%r\ [%{strlen(&ft)?&ft:'aucun'},%{strlen(&fenc)?&fenc:&enc},%{&fileformat},ts:%{&tabstop}]%{fugitive#statusline()}%=%l,%c%V\ %P
elseif has("cmdline_info")
set ruler " show current line and column number
endif