bin/mutt-html2txt

Thu, 11 Apr 2024 21:48:30 -0500

author
Meredith Howard <mhoward@roomag.org>
date
Thu, 11 Apr 2024 21:48:30 -0500
changeset 1147
23f9b157fe8a
parent 564
81f1da7a57e1
permissions
-rwxr-xr-x

Load indentscope even on new nameless bufs

564
81f1da7a57e1 move html dump stuff into one file and customize
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
1 #!/bin/sh
81f1da7a57e1 move html dump stuff into one file and customize
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
2 set -eu
81f1da7a57e1 move html dump stuff into one file and customize
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
3
81f1da7a57e1 move html dump stuff into one file and customize
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
4 LINKS="links -html-tables 0 -html-image-names 0 -html-margin 0"
81f1da7a57e1 move html dump stuff into one file and customize
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
5 FILE=${1:--}
81f1da7a57e1 move html dump stuff into one file and customize
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
6
81f1da7a57e1 move html dump stuff into one file and customize
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
7 [ "$FILE" != '-' ] &&
81f1da7a57e1 move html dump stuff into one file and customize
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
8 exec $LINKS -dump $FILE
81f1da7a57e1 move html dump stuff into one file and customize
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
9
81f1da7a57e1 move html dump stuff into one file and customize
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
10 TMPHTML="$(mktemp).html"
81f1da7a57e1 move html dump stuff into one file and customize
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
11 cat > $TMPHTML
81f1da7a57e1 move html dump stuff into one file and customize
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
12 $LINKS -dump $TMPHTML
81f1da7a57e1 move html dump stuff into one file and customize
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
13 rm -f $TMPHTML

mercurial