crabmail

Static HTML email archive viewer in Rust
git clone git://git.alexwennerberg.com/crabmail
Log | Files | Refs | README | LICENSE

commit 07f2c85e53addb699f31f2928562a4f4891438ab
parent 9c315c6a8ad02f7b0b9fe84eaa23ab10aeb51623
Author: alex wennerberg <alex@alexwennerberg.com>
Date:   Sun, 26 Dec 2021 08:14:22 -0800

Add quoted body in email reply mailto: link

Diffstat:
Msrc/main.rs | 8+++++++-
1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/src/main.rs b/src/main.rs @@ -347,7 +347,13 @@ impl Email { pushencode("cc", &from); pushencode("in-reply-to", &self.id); pushencode("subject", &format!("Re: {}", thread_subject)); - url.pop(); + // quoted body + url.push_str("body="); + for line in self.body.lines() { + url.push_str("%3E%20"); + url.push_str(&urlencoding::encode(&line)); + url.push_str("%0A"); + } url.into() }