* David T-G ([EMAIL PROTECTED]) [010808 09:47]:
> the question, right? :-) If I get annoyed I just 'e'dit the message,
> 'J'oin up the line(s) in vim, save it, and then read it again, but
> the same thing (probably dropping even more to the next line thanks to
> the additional indentation of two sets of quotes) will happen when the
> message turns around again.
>
> I could imagine a vim macro that would look for a line starting with
> a few (well, mebbe one is valid) indent_string chars, another line
> (maybe shorter than length X) without any, and another line with the
> same number of indent_string chars and would then go back to the upper
> line and join up the bare one...
What works really well in vim is to 'J'oin the lines, and then '{gq}'
them. Vim is smart about wrapping when all lines have the same "> "
indent on them, so if you join them, set textwidth to an appropriate
value, and then re-wrap them, it will be well prepared for the next
iteration.
A macro might be able to just tell which lines need to be joined by
looking for lines without the "> " and executing "kJ", then once it was
done '1G','/^$','gqG' (to re-wrap just the body). An example this simple
would surely fail with multiple levels of indentation in a message,
though.
--
Vineet http://www.anti-dmca.org
Unauthorized use of this .sig may constitute violation of US law.
Qba'g gernq ba zr! |tr 'a-zA-Z' 'n-za-mN-ZA-M'
PGP signature