Add "set expandtab" to your .vimrc.
And also add the following two commands:
set tabstop=4
set shiftwidth=4
If you want to convert the existing tabs to spaces, please use :retab command.
本文介绍如何在Vim编辑器中设置tab宽度为4个空格,并提供将现有制表符转换为空格的方法。通过在.vimrc文件中添加特定命令实现此目的。
Add "set expandtab" to your .vimrc.
And also add the following two commands:
set tabstop=4
set shiftwidth=4
If you want to convert the existing tabs to spaces, please use :retab command.
8845

被折叠的 条评论
为什么被折叠?