$./vim-scoops --learn▉
Learn vim motions with an ice-cream van.
The van is your cursor and the town is your text. Learn Vim motions the tasty way.
Try it: one quick level
Drive the van onto the customer with h j k l.
How to play
Learn the basics, then you're going.
Pick a route
Each level on the town map teaches a small set of motions, shown as badges with what they do.
Drive the van
Press keys to move, with no mouse or arrow keys. The panel echoes every key you press so you can see your motions.
Serve under par
Reach every customer. Match the keystroke par to clear it; beat it to earn a Wizard rank.
New to vim? Read this first
Vim edits text with the keyboard alone. Instead of clicking or holding an arrow key, you press single keys that move the cursor precisely, such as one word forward or to the end of a line. Those keys are called motions, and they are what make experienced vim users fast. This game teaches them one at a time.
You're always in Normal mode here, so every key is a command. Put a number in front to repeat (3j moves down three), and if a key seems to do nothing it's usually waiting for a second key, like f then the letter to jump to. The panel tells you when it's waiting.
Motion & command reference
Every motion the game teaches. Each level only shows the few it needs.
Moving
| h j k l | Move left, down, up, right |
| 0 ^ $ | Line start, first shop, line end |
| w / b / e | Hop forward / back / to block end |
| W B E | Same, but over punctuation too |
| gg / G | Jump to the top / bottom row |
| fx / Fx | Fly right / left onto letter x |
| tx / Tx | Pull up before / after letter x |
| ; / , | Repeat the last f/t hop, fwd / back |
| 3j | A count before a key repeats it |
Editing
| x | Delete the character under the cursor |
| rc | Replace that character with c |
| dd / yy | Cut / copy the whole line |
| dw de d$ | Delete to a motion (pair d with a move) |
| p / P | Paste after / before the cursor |
| xp | Swap two neighbours |
| di" di( | Delete inside quotes/brackets (da includes them) |
| . | Repeat your last change |
| u / Ctrl+r | Undo / redo |
Insert mode
| i / a | Type before / after the cursor |
| I / A | Type at the line start / end |
| o / O | Open a line below / above |
| cc / C | Change the line / to end of line |
| s | Delete a char and start typing |
| ciw ci" | Change a word or the text inside quotes |
| Esc | Back to normal mode |
Visual mode
| v | Highlight a range as you move |
| V | Highlight whole lines |
| Ctrl+v | Highlight a column (block) |
| d / y / c | Delete / copy / change the highlight |
| rc | Replace every highlighted char with c |
| o | Jump to the other end |
Search
| /textEnter | Search and jump to the next match |
| n / N | Next / previous match |
| * | Search the word under the cursor |
Registers & macros
| "ayy | Copy the line into bin a (any a-z) |
| "ap | Paste from bin a |
| qa … q | Record keys into bin a, then stop |
| @a | Replay bin a (count works: 3@a) |
| @@ | Replay the last routine |