From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/84740 Path: news.gmane.org!not-for-mail From: Eric Abrahamsen Newsgroups: gmane.emacs.gnus.general Subject: Re: gnus-posting-styles vs compose-mail Date: Mon, 04 Aug 2014 10:12:58 +0800 Message-ID: <87fvhdj93p.fsf@ericabrahamsen.net> References: <87mwbssfqu.fsf@blah.blah> <8738diz39r.fsf@ericabrahamsen.net> <87iombo8qs.fsf@blah.blah> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1407118470 3310 80.91.229.3 (4 Aug 2014 02:14:30 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 4 Aug 2014 02:14:30 +0000 (UTC) To: ding@gnus.org Original-X-From: ding-owner+M32983@lists.math.uh.edu Mon Aug 04 04:14:24 2014 Return-path: Envelope-to: ding-account@gmane.org Original-Received: from util0.math.uh.edu ([129.7.128.18]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1XE7n5-0003DE-1v for ding-account@gmane.org; Mon, 04 Aug 2014 04:14:23 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu) by util0.math.uh.edu with smtp (Exim 4.63) (envelope-from ) id 1XE7m8-0004JH-Lv; Sun, 03 Aug 2014 21:13:24 -0500 Original-Received: from mx2.math.uh.edu ([129.7.128.33]) by util0.math.uh.edu with esmtps (TLSv1:AES256-SHA:256) (Exim 4.63) (envelope-from ) id 1XE7m6-0004J9-4w for ding@lists.math.uh.edu; Sun, 03 Aug 2014 21:13:22 -0500 Original-Received: from quimby.gnus.org ([80.91.231.51]) by mx2.math.uh.edu with esmtps (TLSv1:AES128-SHA:128) (Exim 4.76) (envelope-from ) id 1XE7m4-00021J-QB for ding@lists.math.uh.edu; Sun, 03 Aug 2014 21:13:21 -0500 Original-Received: from plane.gmane.org ([80.91.229.3]) by quimby.gnus.org with esmtp (Exim 4.80) (envelope-from ) id 1XE7m2-0004uv-Rl for ding@gnus.org; Mon, 04 Aug 2014 04:13:18 +0200 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1XE7m1-0001dG-56 for ding@gnus.org; Mon, 04 Aug 2014 04:13:17 +0200 Original-Received: from 111.197.154.245 ([111.197.154.245]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 04 Aug 2014 04:13:17 +0200 Original-Received: from eric by 111.197.154.245 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 04 Aug 2014 04:13:17 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 31 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 111.197.154.245 User-Agent: Gnus/5.130012 (Ma Gnus v0.12) Emacs/24.4.50 (gnu/linux) Cancel-Lock: sha1:MHCNWlVRUxXVNFUCcXWg/d3K7cY= X-Spam-Score: -0.7 (/) List-ID: Precedence: bulk Xref: news.gmane.org gmane.emacs.gnus.general:84740 Archived-At: Kevin Ryde writes: > Eric Abrahamsen writes: >> >> I think no, posting styles won't look at the headers of messages you >> compose. > > Hmm, yes, a bit early. > >> How would gnus know which of the >> gnus-posting-style entries were meant to match on outgoing messages, and >> which meant to match on replied messages? > > Oh, it would have to be some different pattern form or something. > I suppose there's only a few common compose-mail starts. > M-x report-emacs-bug or M-x debian-bug would be main ones. FWIW, Gnorb has something halfway similar to this with BBDB-based posting styles. Basically you write a set of posting-style rules, similar to gnus posting styles but matching on BBDB record fields. That will set fields on the composed message. That means it's contact-centric, which isn't what you're asking for. You need to use `gnorb-bbdb-mail' rather than `bbdb-mail' to make it work. But the end effect would be similar: eg "Any message composed to a contact with a 'foo' field value of 'bar', set my outgoing Organization header to 'baz." Or what have you. See `gnorb-bbdb-posting-styles' for details. https://github.com/girzel/gnorb