diff options
author | Hugues Hiegel <hugues@hiegel.fr> | 2011-10-14 14:49:16 +0200 |
---|---|---|
committer | Hugues Hiegel <hugues@hiegel.fr> | 2011-10-14 14:49:16 +0200 |
commit | 5744d8415a52dbb454870f8c22f4394cacd0f29a (patch) | |
tree | 87553d902078e19bc9867264f8e258379389bfb8 | |
parent | fd704477f6bc3427581bcc4a0de3b204374750a1 (diff) |
[Vim] mail hooks/binds
-rw-r--r-- | vimrc | 10 |
1 files changed, 6 insertions, 4 deletions
@@ -118,7 +118,10 @@ set noexpandtab map U yyp:s/[^ ]/-/g<CR>:noh<CR> map Y yyp:s/[^ ]/=/g<CR>:noh<CR> -map <ESC>Q v/$\n\n<CR>J:.!fmt -tcw78<CR>:noh<CR> + +" Reformatting is done using 'gq<motion>' +map <ESC>Q :s/^/> /<CR> +map <ESC>q :s/^[ ]*>[ ]*//<CR> map <ESC>u :noh<CR> @@ -188,11 +191,10 @@ map <ESC>b :GitBlameCurrentLine<CR> " <ESC>n goto next empty reply-to paragraph " <ESC>m opens an empty reply-paragraph at this line -" <ESC>d deletes everything until but the signature +" <ESC>d deletes everything from there onto the signature " <ESC>w reformats entire mail but the signature -" <ESC>D deletes everything until but the next reply-to § +" <ESC>D deletes all the quote above autocmd BufRead /tmp/mutt-*[0-9a-f] map <ESC>n /^> $<CR> -autocmd BufRead /tmp/mutt-*[0-9a-f] map <ESC>m 'ddO<CR><CR><ESC>-I autocmd BufRead /tmp/mutt-*[0-9a-f] map <ESC>D ^d?^\([^>]\\|$\)?+<CR>O<ESC> autocmd BufRead /tmp/mutt-*[0-9a-f] map <ESC>d ^d/^-- $<CR>O<ESC> autocmd BufRead /tmp/mutt-*[0-9a-f] map <ESC>w ggv/^-- $<CR><UP>:!par rTbgqRe 'B=.,?_A_a' 'Q=_s>\|'<CR> |