Peter Pearson
2017-01-29 05:33:29 UTC
I've been using this line in my .mailcap, happily, for years:
text/html; w3m -I %{charset} -T text/html %s; nametemplate=%s.html; \
copiousoutput
(It's all one line, but I've broken it here for readability.)
With this line, HTML content gets rendered as plain text (reasonable),
but the status line at the bottom of the window doesn't indicate that
w3m has been invoked. But maybe that's OK. If I "view attachments"
and select an HTML part, there's an indication that w3m has been
invoked, and w3m's output seems to have been piped through a pager.
In an attempt to get more sophisticated w3m functionality, I removed
the "; copiousoutput" at the end of the line. To my surprise, this
results in the message "mailcap entry for type text/html not found"
appearing at the bottom of the window. Yet, if I "view attachments"
and select an HTML part, w3m displays it in a nice, link-clickable
way; so obviously the text/html mailcap entry *has* been found.
Can anybody explain why mutt (a) stops finding the mailcap entry
when I remove the copiousoutput from the end, and (b) uses the
mailcap entry after reporting that it couldn't find it? I'm
quite baffled.
Thanks.
$ mutt -version
Mutt 1.5.21 (2010-09-15)
text/html; w3m -I %{charset} -T text/html %s; nametemplate=%s.html; \
copiousoutput
(It's all one line, but I've broken it here for readability.)
With this line, HTML content gets rendered as plain text (reasonable),
but the status line at the bottom of the window doesn't indicate that
w3m has been invoked. But maybe that's OK. If I "view attachments"
and select an HTML part, there's an indication that w3m has been
invoked, and w3m's output seems to have been piped through a pager.
In an attempt to get more sophisticated w3m functionality, I removed
the "; copiousoutput" at the end of the line. To my surprise, this
results in the message "mailcap entry for type text/html not found"
appearing at the bottom of the window. Yet, if I "view attachments"
and select an HTML part, w3m displays it in a nice, link-clickable
way; so obviously the text/html mailcap entry *has* been found.
Can anybody explain why mutt (a) stops finding the mailcap entry
when I remove the copiousoutput from the end, and (b) uses the
mailcap entry after reporting that it couldn't find it? I'm
quite baffled.
Thanks.
$ mutt -version
Mutt 1.5.21 (2010-09-15)
--
To email me, substitute nowhere->runbox, invalid->com.
To email me, substitute nowhere->runbox, invalid->com.