Vim (Vi IMproved) is the modern, feature-rich descendant of vi, written by Bram Moolenaar in 1991. It preserves vi's modal editing model while adding syntax highlighting, multi-level undo, visual mode, split windows, tabs, completion, a plug-in ecosystem, and a built-in scripting language (Vimscript). On most Linux systems, typing vi actually runs Vim, which has become the terminal text editor of choice for a huge fraction of Linux users.
Key features distinguishing it from vi:
- Visual mode (
v,V,Ctrl+V) — select text interactively - Multi-level undo (
u,Ctrl+R) — vi had only one level - Syntax highlighting for hundreds of languages
- Plugins managed by Vim-Plug, Pathogen, Vundle, or native
packadd - Split windows (
:split,:vsplit) and tabs (:tabnew) - Command-line history and search history
- Buffers — multiple files open simultaneously
Configuration lives in ~/.vimrc (or ~/.vim/vimrc), a script in Vimscript that sets options, defines mappings, and loads plug-ins. Modern alternatives include Neovim, a fork focused on extensibility and Lua scripting that has gained substantial momentum in recent years. Both remain fiercely competitive, and either is a solid choice for someone investing time in a terminal editor.
Discussed in:
Also defined in: Textbook of Linux