HOWTO Enter Spaces instead of Tabs in VI & VIM

July 9, 2013

Spaces vs. Tabs are generally annoying when editing files, but start programing in Python and this turns into a complete disaster. Simple solution, always insert Spaces instead of a Tab and you are good to go (my personal preference):

set tabstop=4set shiftwidth=4set expandtab

If you want to be really fancy:

:retab

Will convert all of the existing Tabs into Spaces.

Check out Converting tabs to spaces on the VIM Wiki.

Transform your business without wasting money.

We help you identify, audit and implement technology changes within your business to create leverage points to scale your company faster.