pug, and python are both indent-sensitive languages. I believe that if you have your editor correctly configured this can serve as an advantage, but if it is not correctly configured it's quite a bit of a nuisance. Are there any settings I should have in my vim to make it easy to indent with the correct number of spaces each time I press tab to indent?
I think expandtab
is what you are looking for. It will make tab insert a number of spaces (defined by other options) instead of an actual tab.
See: :h expandtab
, :h shiftwidth
, :h tabstop
, :h softtabstop
, and :h filetype-indent
. These are all that settings that affect tabs/indentation that I know of.
filetype plugin indent on
. That should take care of most nuisances. – Sato Katsura Aug 22 '16 at 17:02