David,

I don't know how you're getting the 'indenter' program to indent
all your lines.  I noticed something peculiar when handling the
mail in emacs.

So the message that mutt shows as the inline attached text
file is "/tmp/mutt-stharms-lnx-27003-79".  Here's the 'head' of
that file:

:On Fri, Nov 16, 2001 at 05:56:02PM -0800, issu wrote:
:>The notes for your case #4404675 have been electronically updated byu user.. Please 
:review and handle as necessary.
:>
:>UPDATE:   Steven,
:>

This is after having (F)iltered it thru my 'indenter' which puts a
single ':' at the front of $_ from the STDIN file handle.

Now if I (E)dit the file i notice in emacs' buffer name line that
the file I'm editing is:

/tmp/mutt-stharms-lnx-27003-87.

Running 'head' on this file produces:

From: "Steven G . Harms" <[EMAIL PROTECTED]>
To: issu <[EMAIL PROTECTED]>
Cc: 
Bcc: 
Subject: Re: (Case #4404675) for ayazdi has been updated.


Lo!  My belov'd headers are there!  It would seem that Mutt keeps the
"text+headers" in one file; upon save and return to mutt it
splits the headers OUT and treats the text section as another
file entirely.

This flies entirely in the face of what you say you were able
to accomplish.  Does a similar effect NOT happen to you?

I assume it's not a version difference thing.

I'm going to see if manually prepending the headers I desire can 
get me the results I want.  I doubt it though.

(thanks for all the perl help from the mongers BTW)

Steven



On Thu, Nov 15, 2001 at 09:40:35AM -0800, Steven G. Harms wrote:
>David,
>
>I thought I was on the right path with what you'd given me, regrettably,
>I've not found a way to make this work.
>
>When using Mutt, I Use emacs as the editor and mutt then creates an
>ascii attachment from a file located in /tmp.  I realized that I could
>use the 'F' option to filter this tmpfile through a perl script or
>something of that nature.
>
>Regrettably, it seems that mutt chooses NOT to touch the headers -
>even when edit_headers=yes.  Here was my test.
>
>I created 'hm.pl' which looks like:
>
>#!/usr/local/bin/perl
>
>while (<STDIN>){
>  chomp;
>  print "-->$_\n";
>}
>
>With the ultimate goal of adding something like 
>
>if (/Subject/){$user_to_cc=s/stuff//; $_="Cc:$user_to_cc\n";print;}
>
>So hm.pl was a preliminary test of manipulation.  
>
>So here's a reply I passed through it:
>
>------
>To: David T-G <[EMAIL PROTECTED]>
>Cc:
>Bcc:
>Subject: Re: send-hook to parse entry out of subject line and dump into CC field?
>Reply-To:
>In-Reply-To: <[EMAIL PROTECTED]>; from davidtg-muttusers@justpickon\
>e.org on Wed, Nov 14, 2001 at 01:58:41PM -0500
><snipped X-headers>
>X-Work-Focuses:  Email Server Maint. & Routing, Cisco Linux
>
>-->Let's show David T-G what it looks like thru ./hm.pl
>-->
>-->On Wed, Nov 14, 2001 at 01:58:41PM -0500, David T-G wrote:
>-->>Steven --
>-->>
>
>-------
>
>As you can see, the filter operation worked ONLY on the non-header data.
>
>Possible solutions:
>
>1.  Find out the name of the /tmp/file (is it in a variable?) and then
>    execute some | command to insert the appropriate cc line into the
>    text.
>
>    I don't think this will work though.  If there's still the
>    'header' versus 'ascii attachment [i.e. content] bifurcation,
>    having the ability to write to that text file isn't
>    going to affect the headers.
>
>2.  Find a way to access the headers themselves?
>
>---------------------------------------------------------------------
>
>BUT!!! I don't understand why this is.  Even as I type this message to
>you, emacs tells me your message is "/tmp/mutt-stharms-lnx-20706-83".
>If i run cat on that in another X-term i see:
>
>From: "Steven G. Harms" <[EMAIL PROTECTED]>
>To: David T-G <[EMAIL PROTECTED]>
>Cc: Mutt Users' List <[EMAIL PROTECTED]>
>Bcc: 
>
>The header info in there plain as day.  I guess when you terminate
>the editor, mutt must move the 'header' content from the editor's
>temp file into the 'header' and then leave the body as the
>text attachment.  This, of course, being the only thing operated
>upon by the 'F' option.
>
>Anyway, it appears I'm at an impasse.  Anyone out there have any
>ideas?
>
>Steven
>
>On Wed, Nov 14, 2001 at 01:58:41PM -0500, David T-G wrote:
>>Steven --
>>
>>...and then Steven G. Harms said...
>>% Regrettably not, i'm talking IMAP to my server..
>>
>>Ah.  That makes it a little trickier.
>>
>>
>>% 
>>% Is it possible to to maybe pipe that to a little shell scrp that
>>% could parse the right field, and then pump that back INTO mutt 
>>% in the CC field???
>>
>>At this point I'd probably ensure that edit_headers is turned on so that
>>you get the whole shebang and use sed (or awk) to capture the subject
>>line and spit out a cc: line (you can just tack that onto the headers as
>>an additional line; mutt will handle it) and then dive into your editor
>>as usual.
>>
>>Hmmm...  Actually, $editor will be handed the name of an existing file,
>>so you might want to do this in perl where you can write back to the
>>file easily.
>>
>>
>>% 
>>% Anyone?
>>
>>Have fun :-)  Post your results, too!
>>
>>
>>% 
>>% steven
>>
>>
>>:-D
>>-- 
>>David T-G                      * It's easier to fight for one's principles
>>(play) [EMAIL PROTECTED] * than to live up to them. -- fortune cookie
>>(work) [EMAIL PROTECTED]
>>http://www.justpickone.org/davidtg/    Shpx gur Pbzzhavpngvbaf Qrprapl Npg!
>>
>
>
>
>-- 
>[The first attachment to this email is a cryptographic signature.
>I protect my privacy by using GnuPG for Linux]
>
>         ||                     ||          Steven G. Harms 
>        :||:                   :||:         [EMAIL PROTECTED]
>       ::||::                 ::||::        [EMAIL PROTECTED]
>     .:::||:::.             .:::||:::.      (408)525-1767 
>...::::::||::::::. . . . ..:::::||::::::... 
>[[Cisco Systems:  Empowering the Internet Generation]]
>



-- 
Steven G. Harms [my opinions are my own, not my employer's]

Some mail readers may interpret this messag as having an 'attachment'
this is actually my cryptographic signature.  Protect your privacy by
using cryptography.  You can get my public encryption key at:

http://pgp.dtype.org:11371/pks/lookup?op=get&search=0xE84048BF

Attachment: msg20556/pgp00000.pgp
Description: PGP signature

Reply via email to