Paragraphs and sentences
In prose the foil is white space: ip and is are a paragraph and a sentence, ap and as add the blank line or space after, so dap and das cut cleanly; ( and ) hop sentences.
Wednesday, 9:30 a.m. The kitchen's write-ups for the website arrive in menu.md: a paragraph per item, a few sentences each, and a few sentences too many. Your job is the editing.
Prose has wrappings too. You don't select a sentence; you name it.
Warm-up from earlier chapters
Two from earlier chapters, from memory, before the new idea. Two wrong tries show the answer.
A paragraph in its foil
You met paragraphs in the long file: lines between blank lines, the stops for { and }. ip is a paragraph's filling, its lines. ap is the paragraph in its foil, which for prose is white space: the blank line after it. So dap removes a paragraph and leaves exactly one blank line between its neighbours.
# Today's menuAl Pastor is pork, marinated overnight with chilli andpineapple. It's our best seller. Order it spicy.Carnitas is pork shoulder, slow-cooked for six hours.Crisp edges, soft middle.Garden Veggie is black beans, peppers and rice. It's vegan.Nobody believes it.# Today's menuAl Pastor is pork, marinated overnight with chilli andpineapple. It's our best seller. Order it spicy.Carnitas is pork shoulder, slow-cooked for six hours.Crisp edges, soft middle.Garden Veggie is black beans, peppers and rice. It's vegan.Nobody believes it.Junk paragraphs
Placeholder paragraphs dropped into the Markdown files. dap from any line of each one.
This exercise needs a keyboard. Read on, and play it at your computer.
Sentences
To Vim a sentence ends at a ., ! or ? followed by a space or the end of a line, and it can run across lines. is is the sentence, from its first letter to its full stop; as adds the space after it. das deletes a sentence cleanly from the middle of a paragraph; cis rewrites one and keeps everything around it.
Al Pastor is pork, marinated overnight with chilli andpineapple. It's our best seller. Order it spicy.Al Pastor is pork, marinated overnight with chilli andpineapple. It's our best seller. Order it spicy.Fewer words
Al Pastor's last sentence goes (das), Carnitas gets a better second sentence (cis), and Birria loses the sentence about simmering. That last one has an abbreviation in it: after the first das, look at what's left before you go on.
Stuck? Show a hint
The first exercise of every lesson is free. Pro unlocks the rest, every track, for good.
See ProThis exercise needs a keyboard. Read on, and play it at your computer.
The last sentence
The cursor is in the last sentence of the paragraph, and nothing follows it on the line. You press das. What is left of the line?
Sentence by sentence
) hops to the start of the next sentence and ( back to the start of this one (or the previous). Handy for reading prose a sentence at a time, and for getting into the sentence you want to change.
Prose, from memory
Press the keys.
Copy edit
Ten junk paragraphs and doubled words across the Markdown files.
The first exercise of every lesson is free. Pro unlocks the rest, every track, for good.
See ProThis exercise needs a keyboard. Read on, and play it at your computer.
The kitchen’s write-up
10:15. The kitchen's draft, top to bottom: "It's our best seller" has to go, the TODO paragraph goes, the sentence about 2019 goes, and "Nobody believes it." becomes "Even meat-eaters order it."
The first exercise of every lesson is free. Pro unlocks the rest, every track, for good.
See ProThis exercise needs a keyboard. Read on, and play it at your computer.
Extra practice optional
The chapter is done. These rounds keep going as long as you like: stop whenever it stops being useful.
Prose, endlessly
Endless junk paragraphs and doubled words in the Markdown files.
The first exercise of every lesson is free. Pro unlocks the rest, every track, for good.
See ProThis exercise needs a keyboard. Read on, and play it at your computer.