Re: [notmuch] keeping a copy of sent mail locally

Subject: Re: [notmuch] keeping a copy of sent mail locally

Date: Sun, 20 Dec 2009 19:22:55 +0100

To: Keith Packard, Alex Ghitza, Carl Worth, Jed Brown, notmuch@notmuchmail.org

Cc:

From: Marten Veldthuis


On Sat, 19 Dec 2009 21:02:18 -0800, Keith Packard <keithp@keithp.com> wrote:
> We actually want to let the user *select* an email address from the
> config file, and then automagically set the bcc: flag as
> appropriate. Without that, I'd end up bcc'ing all of my mail through my
> home address, which would end up sending work email unencrypted to my
> house. Sub-optimal

There's a message-send-hook, which we should probably use. Something
like:

  (add-hook 'message-send-hook 'notmuch-always-bcc-sender)
  (defun notmuch-always-bcc-sender ()
    (message-add-header (concat "Bcc: "
                                (message-fetch-field "From"))))

Though I've just scrabbled this together from the docs, I think it
should work (haven't tried it though).

-- 
- Marten

Thread: