[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: pipe attachments in mutt



-- Sandip P Deshmukh <deshmukh@escortsmumbai.com> wrote
(on Monday, 11 November 2002, 05:20 PM +0530):
> On Mon, Nov 11, 2002 at 11:12:24AM +0000, Glyn Kennington wrote:
> > Sandip P Deshmukh wrote:
> > > > Things you can do: If you have any pdf files saved, type `see filename.pdf'
> > > > and see what happens.
> > > works perfectly! opens xpdf and the file
> > 
> > Well in that case, the problem almost certainly lies with mutt, because
> > `see' is a program to call the appropriate mailcap entry.  (You can test
> > again by trying to look at a pdf file in lynx, though.)
> > 
<snip>
> >  And
> > have you altered any mailcap_* entries in your .muttrc?  This is a shot in
> > the dark, but it's the only remaining thing I can think of.  If that's not
> > it, you might do better asking on a mutt mailing list.
> 
> all my mailcap_* entries in my .muttrc are commented out!!
Good -- that means that it should be looking in standard places for
mailcap entries: /etc/mailcap and ~/.mailcap

I use the following entries in my ~/.mailcap file. If you don't have a
~/.mailcap file, you can simply create one. Here they are:

    text/html;/usr/bin/links %s; needsterminal
    text/x-vcard; /home/matthew/bin/mutt.vcard.filter; copiousoutput
    application/octet-stream; /home/matthew/bin/mutt.octet.filter.pl %s; copiousoutput
    application/pdf; /usr/bin/xpdf %s; test=test "$DISPLAY" != ""; description=Portable Document Format; nametemplate=%s.pdf

The first line pipes any html directly to links; I also have the line
"auto_view text/html" in my .muttrc, which causes the output to return
to mutt. The next two lines are filters you can find from the various
mutt faqs out there, and are used to 1) output vcard information, and 2)
guess what type of file came through as an application/octet-stream (the
default attachment type for a number of sub-par email clients). The last
one launches xpdf on the temp file created by mutt for the
application/pdf attachment.

By the way -- the pdf one I found in my /etc/mailcap file, and is
standard on Debian, from what I can tell.

-- 
Matthew Weier O'Phinney
matthew@weierophinney.net



Reply to: