- :set autoindent 设定自动缩进 Ctrl-D 回到上一层缩进,缺省 noai other:set ai
:set ignorecase 搜索时忽律大小写,缺省 noic other:set ic
:set number 显示行号 缺省 nonu other:set nu
:set scroll=25 设定滚屏行数,缺省尾1/2屏幕 other:set scr=25
:set shell=bash 设定缺省shell other:set sh=bash
:set shiftwidth=4 设定自动缩进 other:set sw=4
:set showmatch 显示匹配的括号 () {} 等 other:set sm
:set showmode 处于 input mode 时显示提示信息 缺省为 :setosmd other:set smd
:set slowopen 在insert 时延迟屏幕刷新 缺省为:set noslow other:set slow
:set tabstop=4 设置 tab 键长度 其它:set ts=4 - 建议在用户目录下编辑一个.exrc的文件,里面保存你的vi编辑环境设置,
一个设置一行,如
set ts=3
set ai
另外,要看VI的所有设置,输入set all
VI 常用设置
最新推荐文章于 2024-03-27 13:58:29 发布