Tuesday, September 7, 2010

vim equivalent of save-excursion in emacs

I came up with this mapping to reformat the current paragraph

imap <leader>. <Esc>{V}!par<CR>i

when the command is done the cursor will be at the beginning of the
paragraph rather than where ever it was when the command was issued.

In emacs I solve this with save-excursion. What do I do in vim?

oivvio

--
http://pipedreams.polite.se/about/


--
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

No comments: