function! FileSize()
let bytes = getfsize(expand("%:p"))
if bytes <= 0
return ""
endif
if bytes < 1024
return bytes
else
return (bytes / 1024) . "k"
endif
endfunction
set statusline=%1* "color to user mode 1
set statusline+=%<%t%w%h%m%r "tail of current file and its flags
set statusline+= [%{strlen(&fenc)?&fenc:'none'}/ "file encoding /
set statusline+=%{&ff}/ "file format /
set statusline+=%Y] "file type
set statusline+= [%{getcwd()}] "cwd() ;-)
set statusline+= %{FileSize()}
set statusline+=%= "align the rest to right
set statusline+=%-7.(%l of %L [%p%%] - Col: %c%V%) "Current line, percentage of size, column
set laststatus=2
Gives me this:
Incidentally, the erlang brush for SyntaxHighlighter is the closest for vim config files.