1、vim 设置tab为4个空格

vim /etc/vimrc

  1. # 在文件末尾添加
  2. set ts=4
  3. set expandtab
  4. set autoindent

保存退出即可
:x