修改root/etc/vim/vimrc文件
set nu //显示行号 filetype on //检测文件类型 set autoindent //自动对其 set smartindent //选择只能对齐方式 set tabstop/ts=4 //设置Tab为4个空格(注意等号两边不能有空格) set shiftwidth=4 //设置自动换行4个空格 set showmatch //设置匹配模式

修改root/etc/vim/vimrc文件
set nu //显示行号 filetype on //检测文件类型 set autoindent //自动对其 set smartindent //选择只能对齐方式 set tabstop/ts=4 //设置Tab为4个空格(注意等号两边不能有空格) set shiftwidth=4 //设置自动换行4个空格 set showmatch //设置匹配模式