From: martin f. krafft Date: Thu, 31 Oct 2019 23:23:30 +0000 (+1300) Subject: add pandoc as htmldumper X-Git-Url: https://git.madduck.net/etc/mutt.git/commitdiff_plain/ed7a25f2bc4c9a9e6cc90922f18bfabd675a24f6 add pandoc as htmldumper --- diff --git a/.mutt/htmldump b/.mutt/htmldump index 906bd6d..f5718e8 100755 --- a/.mutt/htmldump +++ b/.mutt/htmldump @@ -27,6 +27,11 @@ if command -v html2markdown >/dev/null; then --decode-errors=replace --images-to-alt - "$2"| \ sed -re 's,^\\--[[:space:]]+$,-- ,' +elif command -v pandoc >/dev/null; then + + exec iconv -f "$2" -t utf-8 | pandoc -s -f html -t markdown_mmd \ + --columns=$WIDTH + elif command -v elinks >/dev/null; then exec elinks -anonymous -localhost -eval "set document.codepage.assume = '$2'" \