How do I integrate a custom build tool or test runner with Vim's :make command and quickfix list?
Vim's :make command runs a build program and automatically loads its output into the quickfix list so you can jump directly to errors and warnings.
category:
config
tags:
#ex-commands
#command-line
#buffers-windows
How do I enable a popup menu for command-line tab completion in Neovim?
Setting wildoptions=pum tells Neovim to use its popup menu for command-line tab completion instead of the traditional horizontal wildmenu bar.
category:
config
tags:
#config
#completion
#command-line
How do I export my syntax-highlighted Vim buffer to an HTML file?
The :TOhtml command converts the current buffer — complete with its syntax highlighting colors — into a standalone HTML file.
category:
command-line
tags:
#ex-commands
#command-line
#editing
How do I join every line matching a pattern with the line that follows it?
The :g/pattern/join command combines the :global command with :join to merge every line matching a pattern with the line immediately following it.
category:
command-line
tags:
#ex-commands
#editing
#command-line
#search
#normal-mode
How do I change the filename associated with the current buffer in Vim without saving to disk?
:file {newname} (short form: :f {newname}) changes the filename Vim associates with the current buffer.
category:
command-line
tags:
#buffers-windows
#command-line
#ex-commands
How do I trigger wildcard filename completion from inside a custom key mapping in Vim?
The wildchar option (default ) triggers wildcard completion interactively on the command line.
category:
config
tags:
#config
#macros
#command-line
#completion
How do I run a normal mode command from the ex command line without triggering my custom key mappings?
:normal {command} runs a sequence of Normal mode keystrokes from the command line (or a range of lines with :%normal), but it applies your custom key mappings.
category:
command-line
tags:
#ex-commands
#macros
#normal-mode
#command-line
How do I redisplay the output from the last Ex command that already scrolled away?
Pressing g or q to dismiss it again Example Tips :messages also shows recent messages (and those accumulate across the session), while g< only shows the last pa
category:
command-line
tags:
#command-line
#ex-commands
#output
How do I configure command-line Tab completion to show a list and complete the longest common match first?
:set wildmode=list:longest,full
Vim's default Tab completion in the command-line cycles through matches one at a time, making it hard to see all available options at once.
category:
command-line
tags:
#command-line
#completion
#config
#ex-commands
How do I right-align a block of text to a specific column width using an Ex command?
Vim has built-in Ex commands for text alignment — :right, :left, and :center — that work over any line range without plugins.
category:
command-line
tags:
#formatting
#indentation
#command-line
#ex-commands
How do I selectively accept LOCAL or REMOTE changes in a three-way git merge using Vim?
When Vim is configured as a git mergetool, it opens a three-way split with the LOCAL (your branch), REMOTE (their branch), and MERGED (the output file) buffers.
category:
buffers-windows
tags:
#buffers-windows
#diff
#editing
#command-line
How do I run a command on every entry in the location list, like a window-local quickfix?
Vim maintains two parallel systems for collections of file positions: the quickfix list (global, one per Vim session) and the location list (local to each windo
category:
command-line
tags:
#command-line
#ex-commands
#buffers
#search
How do I make Vim's command-line tab completion case-insensitive for file and buffer names?
:set wildignorecase makes Vim's command-line tab completion treat uppercase and lowercase letters as equivalent when completing file names, buffer names, and ot
category:
command-line
tags:
#command-line
#completion
#config
#ex-commands
How do I sort lines by a field in the middle or end of each line using a pattern?
The :sort r /{pattern}/ command sorts lines using the text that matches the pattern as the sort key.
category:
command-line
tags:
#command-line
#sorting
#ex-commands
#regex
How do I enable fuzzy matching for command-line tab completion in Neovim?
Enables fuzzy matching for Neovim's command-line tab completion (wildmenu), so you can match any part of a filename, command, or option — not just from the be
category:
command-line
tags:
#completion
#command-line
#neovim
#config
#wildmenu
How do I refer to the current filename, extension, or directory in Vim ex commands?
Vim's filename modifiers let you derive path components from the current file's name directly inside ex commands.
category:
command-line
tags:
#command-line
#ex-commands
#buffers
How do I filter the output of a Vim command to show only lines matching a pattern?
:filter /pattern/ {command}
:filter /pattern/ {command} runs any Ex command but suppresses every output line that does not match the pattern.
category:
command-line
tags:
#command-line
#ex-commands
#search
#buffers
How do I search across all Vim help files for a keyword or phrase?
:helpgrep {pattern} searches all installed Vim help files for a pattern and populates the quickfix list with every match.
category:
command-line
tags:
#ex-commands
#command-line
#search
How do I evaluate a Vimscript expression and use the result as my command-line input?
Pressing e on the command line opens a special prompt that lets you type a Vimscript expression.
category:
command-line
tags:
#command-line
#ex-commands
#vimscript
#insert-mode
How do I create my own custom ex commands in Vim?
:command lets you define new Ex (colon-prefixed) commands with custom names, optional argument handling, and completion.
category:
command-line
tags:
#command-line
#ex-commands
#config
#normal-mode