Tutorial by Examples

In command mode(Esc) enter :gg=G to use Vim's built-in indention engine. Command PartDescriptionggstart of file=indent (when equalprg is empty)Gend of file You can set equalprg in your .vimrc to use a more sophisticated auto-formatting tool. For example, to use clang-format for C/C++ put the foll...
To indent our outdent the current line in normal mode press the greater than > key or the less than < twice accordingly. To do the same on multiple lines just add a number beforehand 6>> CommandDescription>>indent current line<<outdent current line6>>indent next 6 lin...

Page 1 of 1