Once you’ve got expandtab on as per the other answers, the extremely convenient way to convert existing files according to your new settings is:
:retab
It will work on the current buffer.
Once you’ve got expandtab on as per the other answers, the extremely convenient way to convert existing files according to your new settings is:
:retab
It will work on the current buffer.