New comment by anjandev on mblaze repository https://github.com/leahneukirchen/mblaze/issues/166#issuecomment-680193006 Comment: Hi @Anachron, thank you for sharing your approach for opening html emails. I built upon your example for an approach that works for me: ``` ATTACH="$(mshow -t . | dmenu)" MIME="$(echo "$ATTACH" | cut -f 2 -d ":" | cut -f 2 -d " ")" ATTACHNUM="$(echo "$ATTACH" | cut -f1 -d':')" tmp="$(mktemp '/tmp/mblaze.XXXXXX')" mshow -O . "$ATTACHNUM" > "$tmp" # replace this with xdg? case "$MIME" in "application/pdf") zathura "$tmp" ;; "text/html") firefox "$tmp" ;; # More stuff for pngs and stuff? esac ``` I use it as a general tool for extracting all attachments in emails in my email script I made for my pinephone: https://git.sr.ht/~anjan/sxmo-userscripts/tree/master/mail.sh#L79 I dont know if my approach is the best but it works for emails with multi html and works as a general attachment extractor.