Vim - Repeatable Actions and How to Reverse Them

  • Vim’s normal mode is similar to how painters spend the majority of time doing things other than putting paint to paper
IntentActionRepeatReverse
Make a change{edit}.u
Scan line for next charf{char}/t{char};,
Scan line for prev charF{char}/T{char};,
Scan document for next match/pattern<CR>nN
Scan document for prev match?pattern<CR>nN
Scan document for current word*nN
Substitution:s/target/repl&u
Macro sequenceqx{changes}q@xu
  • <C-o> lets you exit insert mode to perform a single normal mode command

References

[1] Drew Neil. “Practical Vim.”

Backlinks