diff options
author | Bence Ferdinandy <bence@ferdinandy.com> | 2024-01-04 21:22:57 +0100 |
---|---|---|
committer | Robin Jarry <robin@jarry.cc> | 2024-01-08 00:11:25 +0100 |
commit | 934308a95aa0c75029c731a64aa99664c4579b29 (patch) | |
tree | 1340ea2077da71ed92cea042fd092f53c4e3d999 | |
parent | cbc56ad1c23a60c5a2de2515461d700b4906f876 (diff) | |
download | aerc-934308a95aa0c75029c731a64aa99664c4579b29.tar.gz aerc-934308a95aa0c75029c731a64aa99664c4579b29.zip |
add info about quoting html when replying
We can't add this to the default template so add info on wiki on how to
solve it.
Signed-off-by: Bence Ferdinandy <bence@ferdinandy.com>
Acked-by: Robin Jarry <robin@jarry.cc>
-rw-r--r-- | configurations/htmlquote.md | 21 | ||||
-rw-r--r-- | configurations/index.md | 1 |
2 files changed, 22 insertions, 0 deletions
diff --git a/configurations/htmlquote.md b/configurations/htmlquote.md new file mode 100644 index 00000000..2e7d2def --- /dev/null +++ b/configurations/htmlquote.md @@ -0,0 +1,21 @@ +--- +title: "aerc-wiki: Configurations/HTML quoting in replies" +--- + +Sometimes the email you get only has `text/html`. If you quote reply this, the +default [quoted_reply +template](https://git.sr.ht/~rjarry/aerc/tree/master/item/templates/quoted_reply) +will dump the entire html with all the markup into the quote. You can update +this template to behave differently if replying to html. For example, add the +html filter shipped with aerc to construct a more sensible text to quote: + +``` +{{ if eq .OriginalMIMEType "text/html" -}} +{{- trimSignature (exec `~/.local/softwarefromsource/aerc/filters/html` .OriginalText) | quote -}} +{{- else -}} +{{- trimSignature .OriginalText | quote -}} +{{- end}} +``` + +Note, that since this filter comes with a third-party dependency (w3m), this +will not be added to the default template shipped with aerc. diff --git a/configurations/index.md b/configurations/index.md index 85be2975..5f819a92 100644 --- a/configurations/index.md +++ b/configurations/index.md @@ -5,3 +5,4 @@ title: "aerc-wiki: Configurations" - [colors](configurations/colors.md) - [notmuch](configurations/notmuch.md) - [style sets](configurations/stylesets.md) +- [html quoting in replies](htmlquote.md) |