On Thu Feb 21, 2002 at 01:47:10PM -0500, Philip Mak wrote: > I suppose I could code some sort of startup code in 'vi' to find and > wrap long lines, but how would I make it only trigger when 'vi' is > being started on composing a new reply (and not any other time, e.g. > editing an existing message)?
Bruno Postle posted a reply for a similar question some time ago, for use with vim: # <F10> reflows the current paragraph and <F11> toggles indenting so # paste works properly. set editor="vim \ -c 'set tw=72 et' \ -c 'set autoindent' \ -c 'set formatoptions=tcq2' \ -c 'set syntax=mail' \ -c 'map <F10> gqap' \ -c 'set pastetoggle=<F11>'" Place the cursor anywhere convenient in the long line, press $ to get to the end of it, and then F10. I'm *very* happy with it. HTH -- Martin Karlsson | I prefer mail encrypted with PGP/GPG! keyid & fingerprint in headers visit http://www.gnupg.org for more info
msg24645/pgp00000.pgp
Description: PGP signature