Vim indentation options
Posted on
tabstop: how many columns a tab should be made up of in the editor view.expandtab: when enabled, insert the appropriate number of spaces when in insert mode.shiftwidth: how many columns text will be indented when using indent operations (such as<<or>>) in normal or visual modesofttabstop: when enabled,softtabstop<tabstop&&noexpandtab, this will result in a combination of tabs and spaces to make up the total spacing .softtabstop==tabstop&&noexpandtab, this will always force the use of tabs.expandtab, the value ofsofttabstopwill be ignored and spaces will be forced
shifround: round indent to nearest multiple of setshiftwidthon indent operations (>><<in Normal mode,CTRL-TCTRL-Din Insert mode)
Source: A byte of Lox (Tabs, stop! The truth about tab and spaces in Vim)