[comp.mail.mush] Forwarding and Resending Mail

jsin@seashell.seas.ucla.edu (Just Another John) (08/21/90)

This was probably discussed before, but...

What's the best way to "forward" and/or "resend" a message to someone else 
using mush, possibly editing the content?  I want it to work similar to
"reply", except it should ask me for the new To: address, and then
perhaps generate some headers indicating "Originally sent to:" and
"Forwarded to:" before putting me in the editor.

I have been saving the message, edit it, and then using the mail command,
but I figure there has to a better way?

Thanks,
--
John (Jonghoon) Sin       (Above opinions are my own etc, etc, etc...)
UCLA SEASnet Facilities   InterNet: jsin@seas.ucla.edu
2567 Boelter Hall         UUCP:  ...!(uunet,ucbvax,rutgers)!seas.ucla.edu!jsin
Los Angeles, CA. 90024    Phone: (213) 825-3556

schaefer@ogicse.ogi.edu (Barton E. Schaefer) (08/21/90)

In article <977@lee.SEAS.UCLA.EDU> jsin@seashell.seas.ucla.edu (Just Another John) writes:
} 
} What's the best way to "forward" and/or "resend" a message to someone else 
} using mush, possibly editing the content?  I want it to work similar to
} "reply", except it should ask me for the new To: address, and then
} perhaps generate some headers indicating "Originally sent to:" and
} "Forwarded to:" before putting me in the editor.
} 
} I have been saving the message, edit it, and then using the mail command,
} but I figure there has to a better way?

Your best bet is to use "mail -Eef" (edit headers, run editor, forward)
and then delete most of the headers mush supplies to use the headers of
the original message (which will be found below the "--- forwarded" line).
You can change the To: line to Originally-To: and so on at that time.

You could also use something like

    cmd SOF 'eval -h "my_hdr Originally-To: %t ; my_hdr Forwarded-From: %f"'
    cmd ROF 'un_hdr Originally-To: ; un_hdr Forwarded-From:'
    cmd SIS 'set old_str="$indent_str" indent_str=""'
    cmd RIS 'set indent_str="$old_str" ; unset old_str'

    cmd resend 'SOF; SIS; m -ei \!*; RIS; ROF'

But that only works for resending the current message, because SOF depends
on getting the To: and From: of the current message.  Oh, if you use the
pre_indent_str or post_indent_str variables, then SIS and RIS have to clean
those up, too ... mush needs perl's local() operator. ;-)
-- 
Bart Schaefer						schaefer@cse.ogi.edu