Ex mode
2,10y
You can copy 9 lines, but the contents are not on the system clipboard.
In normal mode, do this
1。 Jump to line 2
2gg
2。 8″+y copies 8 lines below the current cursor, plus the current line, which is 9 lines.
Can you create a way
In ex mode, enter 2,10″+y to copy lines 2 to 10 to the system clipboard?
:2, 10y +
The order is[range]y[ank] [x]
, of which[x]
Specifies the register for.