<<< Date Index >>>     <<< Thread Index >>>

Re: Viewing encoded attachments



On 2003-10-27, David Fishburn <fishburn@xxxxxxxxxxxxx> wrote:
> Mutt 1.4.1i on Linux RH9      
> 
> When I am reading a message with an attachment, I have to do the
> following:
> 
> Hit |
> Pipe to command: uudecode -o - | less
> 
> I had assumed setting:
> :set pipe_decode=yes
> 
> Would allow me to run:
> Pipe to command: less
> 
> But it doesn't.

If the uuencoded portion is really an attachment, setting
pipe_decode should work fine.  Sometimes, however, a uuencoded file
is simply included in the message body, not as a MIME attachment,
and in that case you will have to explicitly pipe the body through
uudecode.  Mutt trusts the MIME headers and doesn't go looking
inside the message parts for uudecoded blocks.

> Really I would usually want to pipe it into Vim (as the default) and
> override only when necessary.
> 
> Just wondering if there are any simplier methods.

The only thing I can think of is to write a script that saves its
stdin to a temporary file, looks at the contents to see if there is
a uudecoded block, and then sends the temporary file to stdout
either directly or through uudecode as appropriate.

HTH,
Gary

-- 
Gary Johnson                               | Agilent Technologies
garyjohn@xxxxxxxxxxxxxxx                   | Wireless Division
http://www.spocom.com/users/gjohnson/mutt/ | Spokane, Washington, USA