You can set the '
expandtab
' (abbreviated to 'et
') option so each tab that you type is converted to an equivalent number of spaces. And you can use the :retab
command to convert all existing tabs to spaces. You can do both in one command:
:set et|retabYou can also convert spaces to tabs:
:set noet|retab!Both of the above examples should be used with caution. They convert all sequences, even those that might be in a "quoted string like this".
This tip shows how to convert only the indents at the left margin. Any spaces or tabs after the first non-white character are not affected.
Comments
Post a Comment
https://gengwg.blogspot.com/