Editors

vi

Opens the classic modal Unix editor.

vi is the traditional modal editor found on almost every Unix-like system. Vim is an enhanced vi-compatible editor.

Syntax
vi [file]

Arguments explained

  • Options adjust output or behavior.
  • Arguments name the files, services, hosts, or values the command should work with.

Common examples

Open a file
vi /etc/hosts

Opens /etc/hosts in vi.

Save and quit
Esc, then :wq

Leaves insert mode, writes the file, and quits.

vi Command
FieldDetails
Commandvi
CategoryEditors
Primary useOpens the classic modal Unix editor.
Syntaxvi [file]