在vimrc文件中任意地方令起一行插入下面内容
syntax on
set tabstop=4
set shiftwidth=4
set autoindent
set cindent
set cinoptions={0,1s,t0,n-2,p2s,(03s,=.5s,>1s,=1s,:1s
set nu
set softtabstop=4
配置成功之后与预览图:
From:
http://www.linuxidc.com/Linux/2013-11/93013.htm