🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.mail.mh
Article #1933

Re: Saving messages

#1933
From: Brandon S. Allbery
Date: Wed, 13 Dec 1989 23:17
33 lines
2366 bytes
In article <35117@cornell.UUCP> shah@cs.cornell.edu (Amitabh Shah) writes:

   In article <6260@ucdavis.ucdavis.edu>, gfink@iris (George Fink) writes:
   >How do you save a mail message off to a file after it has been inc'ed?
   >The only way I can think of is to cd to the folder's directory, then
   >cp it somewhere else.

   If you use mh within emacs (mh-e) then any inc'ed message can be written to a
   file using ">" command. With standard mh, you can do "show message > file", but
   beware that the file would have the format of your mhl filter.

If you want just the body of the file, try:

		sed '1,/^$/d' `mhpath +folder message`

I have a number of shell scripts which do this, extract files with filenames
on the subject line (as "Subject: Transmittal: filename"), extract uuencoded
files, extract shar files, extract and apply patch files (even catching the
flags listed in the message if the patch is created by metaconfig), etc.

++Brandon
--
Brandon S. Allbery    allbery@NCoast.ORG, BALLBERY (MCI Mail), ALLBERY (Delphi)
uunet!hal.cwru.edu!ncoast!allbery ncoast!allbery@hal.cwru.edu bsa@telotech.uucp
*(comp.sources.misc mail to comp-sources-misc[-request]@backbone.site, please)*
*Third party vote-collection service: send mail to allbery@uunet.uu.net (ONLY)*
expnet.all: Experiments in *net management and organization.  Mail me for info.
-- 
Brandon S. Allbery    allbery@NCoast.ORG, BALLBERY (MCI Mail), ALLBERY (Delphi)
uunet!hal.cwru.edu!ncoast!allbery ncoast!allbery@hal.cwru.edu bsa@telotech.uucp
*(comp.sources.misc mail to comp-sources-misc[-request]@backbone.site, please)*
*Third party vote-collection service: send mail to allbery@uunet.uu.net (ONLY)*
expnet.all: Experiments in *net management and organization.  Mail me for info.
Technical Details
Message-ID: <ALLBERY.89Dec13181730@ncoast.org>
Path: arc1-ca.pugleaf.net!utzoo!attcan!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!tut.cis.ohio-state.edu!mailrus!usenet.ins.cwru.edu!hal!ncoast!allbery
References: <6260@ucdavis.ucdavis.edu> <35117@cornell.UUCP>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!tut.cis.ohio-state.edu!mailrus!usenet.ins.cwru.edu!hal!ncoast!allbery
From: allbery@ncoast.org (Brandon S. Allbery)
Newsgroups: comp.mail.mh
Subject: Re: Saving messages
Message-ID: <ALLBERY.89Dec13181730@ncoast.org>
Date: 13 Dec 89 23:17:39 GMT
References: <6260@ucdavis.ucdavis.edu> <35117@cornell.UUCP>
Sender: allbery@NCoast.ORG (Brandon S. Allbery)
Organization: NCoast Public Access UN*X, Cleveland, OH USA
Lines: 33
In-reply-to: shah@cs.cornell.edu's message of 13 Dec 89 04:35:04 GMT