On 2018-04-10, Yubin Ruan <ablacktsh...@gmail.com> wrote:
> Can anyone share some approaches for reading HTML emails.
> But sometimes I receive some HTML mails which can not be handled
> that well by w3m, so I want to open that html attachment in a
> browser. How can I switch between?
I have my mailcap entry set up so that "viewing" an html message uses
w3m but "printing" an html message opens it in chromium:
$ fgrep text/html ~/.mailcap
text/html; w3m -T text/html -dump; copiousoutput; print = chromiumurl %s;
$ cat ~/bin/chromiumurl
test -f "$URL" && URL="file://$URL"
expr match "$URL" '.*://.*' >/dev/null || URL="http://$URL"
exec chromium "$URL"
Grant Edwards grant.b.edwards Yow! Am I elected yet?