Vim move / copy line to end of file without moving cursor? -
i use :.m$
move or :.t$
copy current line end of file. easier if cursor won't jump end of file or target location of move / copy command. there option it?
give these 2 mappings try:
"move current line end of buffer without moving cursor nnoremap <leader>mv ddgp`` "copy current line end of buffer without moving cursor nnoremap <leader>cp ygp``
note move
case, cursor position changed text of next line, since original line of text has gone. sits on same line (number).
if required anonymous register ("
) untouched, think need write function it.
Comments
Post a Comment