How do I reindent a block of code using a visual selection?
= (in visual mode)
After making a visual selection, pressing = applies Vim's auto-indent to every selected line at once.
49 results for "c motion"
= (in visual mode)
After making a visual selection, pressing = applies Vim's auto-indent to every selected line at once.
=i{ or =ap
The = operator performs smart indentation based on Vim's filetype-aware indent rules.
g; and g,
Vim tracks every position where you made a change in the changelist.
:options
:options opens a special Vim buffer that lists every available option, grouped by category (appearance, editing, search, etc.
vim-matchup
The vim-matchup plugin by Andy Massimino is a drop-in replacement for Vim's built-in matchit plugin that supercharges the % key to work with language-specific k
plugins #plugins #matchup #navigation #text-objects #matching
:'<,'>s/pattern/replacement/g
When you make a visual selection and then type :, Vim automatically inserts ' as the range — the marks for the start and end of the last visual selection.
di(
The di( command deletes everything inside the nearest pair of parentheses without removing the parentheses themselves.
"_d
The "d command deletes text using the black hole register ("), which discards the deleted content instead of storing it.
cw vs ciw
The cw and ciw commands both change a word, but they behave differently depending on cursor position.
editing #editing #text-objects #motions #normal-mode #productivity