在centos下编码时,默认的tab缩进占8个字符,因此在/etc 目录下的vimrc文件末尾添加下列内容就可以改变成4个字符缩进
set nu
if has( “autocmd” )
filetype plugin indent on
autocmd FileType make set tabstop=8 shiftwidth=8 softtabstop=0 noexpandt ab
endif
set tabstop=4
set shiftwidth=4
set softtabstop=4
set expandtab
补全括号,引号可添加下列内容
inoremap ( ()i
inoremap [ []i
inoremap { {}i
inoremap < <>i
inoremap ” “”i
知易行难,加油吧!