procmail
[Top] [All Lists]

copy subject content to body

1998-01-24 16:37:09
Could anyone correct following recipe
so that long subject content is copied to TOP of BODY
rather than BOTTOM of BODY?
And tell me a better way than using "formail without option"?
Headers and body does not seem to feed without it:(

nkf is a program to de-MIME Japanese char header contents.
It's ok to leave original subject header intact.

I have been away from procmail recipe for few months
and now all look abracadabra to me again:< 
So pls bear with me.

#--- subject2body.rc --- 
# Copy long Subject header content to body ( > 20 bytes)
SUBJECT=`formail -xSubject:`
:0
* -20^0
* -18^1 SUBJECT ?? =\?ISO-2022-JP\?B\?.*\?=
* 1^1 SUBJECT ?? .
{ 
  SSUBJECT=`echo "$SUBJECT" | nkf -m`
  :0f                        <=== Pls correct from here and after!
  |  formail ;\
     echo "SUBJECT>$SSUBJECT"; \
     echo "<SUBJECT";
}
#--- end of subject2body.rc ---

TIA
_/_/_/      Mitsuru FURUKAWA      _/_/_/
_/_/_/        Tokyo, Japan        _/_/_/
_/_/_/     mailto:furu(_at_)009(_dot_)com    _/_/_/
_/_/_/  http://www.009.com/furu/  _/_/_/

<Prev in Thread] Current Thread [Next in Thread>