vim ~/.vimrc set ai # 自动缩进 set ts=4 # 4个空格 set et # 将tab转成空格 autocmd FileType yaml setlocal sw=2 ts=2 et ai