I did some digging around Google and came up with this:

[pmak@lina pmak]$ cat .muttvimrc
map <C-J> {gq}                  # Ctrl+J rejustifies current paragraph
set formatoptions=tcroqv        # see :help formatoptions
set comments=nb:>               # rejustify quoted text correctly
set tw=75                       # wrap lines to 75 chars
[pmak@lina pmak]$ egrep editor .muttrc
# load a special vimrc when starting vim from mutt
# and start the cursor at the end of the headers
set editor="vim -u ~/.muttvimrc +/^$"

It doesn't seem to work with all recent versions of VIM, though. It's very
weird---version 6.0z Beta (2001 Mar 24) seems to ignore whatever I put in
"set comments". On version 6.0 (2001 Sep 26), the "set comments" thing
works but I can't map any control keys for some reason (!). I'm still
trying to figure that out.

But the reformatting of lines, even ones with multiple levels of quoted
text, seems to work.

Reply via email to