Yanking and pasting lines
There are two keys to remember: y for yanking, and p for pasting. We’ll
explore a number of ways to use them in this lesson, but to kick us off,
let’s try the simplest yank/paste sequence possible: yanking a whole line
and pasting it back into the buffer.
Remember that in Helix, every action applies to the current selection. So
there is no special “yank a line” command — you select the line with x,
then y yanks whatever is selected. p then pastes the yanked text after
the selection. Because a line selection ends with a newline, the copy lands
on the line below.
You only need to yank the text once, then you can paste it as many times
as you like — and p accepts a count.
Work through the checklist below.