Block Insert and Append
I and A in block mode = insert/append on every selected line.
After Ctrl-V selecting a column-rectangle, I types text inserted at the start of every line in the block; A appends it. The text is inserted on all lines after Esc.
This is the trick most people don't know exists โ and once you know it, you'll use it constantly.
| Key | Note |
|---|---|
| Ctrl-V | Enter block Visual |
| j | Extend down (or count + j) |
| I | Insert at the LEFT edge of the block |
| // | Type your prefix |
| Esc | Now the prefix appears on every selected line |
Watch
- ๐บ #0434 o โ Other End (not yet published)
- ๐บ #0436 gv โ Reselect (not yet published)
See also: The Three Visual Modes, Swap and Adjust Endpoints