原文网址:http://blog.sina.com.cn/s/blog_620ccfbf01010erz.html

为了vim更好的支持python写代码,修改tab默认4个空格有两种设置方法:

1. vim /etc/vimrc  

set ts=4
set sw=4

2. vim /etc/vimrc 

set ts=4
set expandtab
set autoindent

推荐使用第二种,按tab键时产生的是4个空格,这种方式具有最好的兼容性。

原文网址:http://blog.sina.com.cn/s/blog_620ccfbf01010erz.html

为了vim更好的支持python写代码,修改tab默认4个空格有两种设置方法:

1. vim /etc/vimrc  

set ts=4
set sw=4

2. vim /etc/vimrc 

set ts=4
set expandtab
set autoindent

推荐使用第二种,按tab键时产生的是4个空格,这种方式具有最好的兼容性。

相关文章:

  • 2021-11-09
  • 2021-07-14
  • 2022-01-01
  • 2021-05-03
  • 2021-11-09
  • 2021-09-13
  • 2021-12-27
猜你喜欢
  • 2021-11-09
  • 2021-11-09
  • 2021-11-09
  • 2021-11-09
  • 2022-12-23
  • 2021-11-09
  • 2021-11-09
相关资源
相似解决方案