Return-Path: X-Original-To: notmuch@notmuchmail.org Delivered-To: notmuch@notmuchmail.org Received: from localhost (localhost [127.0.0.1]) by arlo.cworth.org (Postfix) with ESMTP id 63F0A6DE034D for ; Fri, 29 Apr 2016 13:56:07 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at cworth.org X-Spam-Flag: NO X-Spam-Score: -2.069 X-Spam-Level: X-Spam-Status: No, score=-2.069 tagged_above=-999 required=5 tests=[AWL=0.242, RCVD_IN_DNSWL_MED=-2.3, SPF_PASS=-0.001, T_RP_MATCHES_RCVD=-0.01] autolearn=disabled Received: from arlo.cworth.org ([127.0.0.1]) by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id yUZ49CKF7nI5 for ; Fri, 29 Apr 2016 13:55:59 -0700 (PDT) Received: from mailchk-m04.uwaterloo.ca (mailservices.uwaterloo.ca [129.97.128.141]) by arlo.cworth.org (Postfix) with ESMTPS id D27D56DE0319 for ; Fri, 29 Apr 2016 13:55:58 -0700 (PDT) Received: from connect.uwaterloo.ca (connhub2.connect.uwaterloo.ca [129.97.149.119]) by mailchk-m04.uwaterloo.ca (8.14.4/8.14.4) with ESMTP id u3TKtrAb021558 (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=OK); Fri, 29 Apr 2016 16:55:54 -0400 Received: from uwaterloo.ca (129.97.68.117) by connhub2.connect.uwaterloo.ca (129.97.149.119) with Microsoft SMTP Server (TLS) id 14.3.266.1; Fri, 29 Apr 2016 16:55:52 -0400 From: Sebastian Fischmeister To: David Edmondson , Notmuch Mail Subject: Re: message-default-mail-headers not working in notmuch 0.22 In-Reply-To: References: <87y47wmsfi.fsf@uwaterloo.ca> Reply-To: X-Homepage: http://esg.uwaterloo.ca Date: Fri, 29 Apr 2016 16:55:52 -0400 Message-ID: <87twik9lt3.fsf@uwaterloo.ca> MIME-Version: 1.0 Content-Type: text/plain X-UUID: 8f016564-773b-448e-a4e0-3245d918b654 X-Miltered: at mailchk-m04 with ID 5723CA59.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Virus-Scanned: clamav-milter 0.99 at mailchk-m04 X-Virus-Status: Clean X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.9 (mailchk-m04.uwaterloo.ca [129.97.128.141]); Fri, 29 Apr 2016 16:55:55 -0400 (EDT) X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Apr 2016 20:56:07 -0000 I can confirm that this fixes the problem. Thanks for the quick reply! Sebastian David Edmondson writes: > On Fri, Apr 29 2016, Sebastian Fischmeister wrote: >> After upgrading to notmuch 0.22, my emacs config seems broken: >> >> (setq message-default-mail-headers "Reply-to: me@example.com\nBcc: me@example.com") >> >> When creating a new mail, it has no header other than "To:" and >> "Subject:". >> >> Since I cannot find any item in the NEWS related to this release, is >> this expected behaviour? > > No, it's not intended. Please try this patch: > > diff --git a/emacs/notmuch-mua.el b/emacs/notmuch-mua.el > index 0445975..399e138 100644 > --- a/emacs/notmuch-mua.el > +++ b/emacs/notmuch-mua.el > @@ -338,7 +338,10 @@ modified. This function is notmuch addaptation of > ;; We need to convert any string input, eg from rmail-start-mail. > (dolist (h other-headers other-headers) > (if (stringp (car h)) (setcar h (intern (capitalize (car h)))))))) > - (args (list yank-action send-actions))) > + (args (list yank-action send-actions)) > + ;; Cause `message-setup-1' to do things relevant for mail, > + ;; such as observe `message-default-mail-headers'. > + (message-this-is-mail t)) > ;; message-setup-1 in Emacs 23 does not accept return-action > ;; argument. Pass it only if it is supplied by the caller. This > ;; will never be the case when we're called by `compose-mail' in