On 2020-02-04 14:27, Tony Mechelynck wrote:
> The following mapping will move the first line from top to bottom of
> the file (at least in Vim in 'nocompatible' mode, I'm not sure about
> vi (or 'compatible' Vim) and nvi):
> 
> :map <F5> :1d<Bar>$put<CR>

Or more simply

  :map <f5> :1m$<cr>

Should work in vi, vim, nvi, neovim, and the same concept/command in
ed(1).  It should also work regardless of your 'compatible' settings.
:-)

(within vim/neovim, I'd tend to use "nnoremap" instead of just "map")

-tim


-- 
-- 
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_use+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_use/20200204075241.1476df4a%40bigbox.attlocal.net.

Reply via email to