How To Force vim to Convert Tabs to Spaces

To create indents with 4 space characters which are entered by pressing the TAB key:
1 |
set tabstop=8 softtabstop=0 expandtab shiftwidth=4 smarttab |
To make the above settings permanent add to your ~/.vimrc file. For more details on any of these see :help ‘optionname’ in vim (e.g. :help ‘tabstop’) tabstop The width of a hard tabstop measured in “spaces” — effectively the […]