Editors

Overview

vi is on every Unix system. When you’re SSH’d into a minimal server, editing over a serial console, or in a rescue environment - vim is there. Modal editing isn’t a preference; it’s a survival skill.

In This Section

Topic Description

Vim Essentials

Comprehensive vim/neovim reference - modes, motions, text objects, registers, macros, and production scenarios.

Vim Quick Survival

i          Enter insert mode
Esc        Return to normal mode
:wq        Save and quit
:q!        Quit without saving
u          Undo
/pattern   Search

Why Modal Editing?

Modeless Vim

Ctrl+Shift+Arrow (select word)

viw (3 keys, no modifiers)

Home, Shift+End, Delete

d$ (delete to end of line)

Find dialog, regex checkbox, replace…​

:%s/old/new/gc (inline, immediate)

The grammar of vim: operator + motion = action

  • d + w = delete word

  • c + i" = change inside quotes

  • y + ap = yank around paragraph