From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/79059 Path: news.gmane.org!not-for-mail From: lee Newsgroups: gmane.emacs.gnus.general Subject: Re: using templates to write articles (email) Date: Fri, 10 Jun 2011 22:46:12 +0200 Message-ID: <87zklpywwf.fsf@yun.yagibdah.de> References: <87fwnhd0mx.fsf@yun.yagibdah.de> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1307756116 16542 80.91.229.12 (11 Jun 2011 01:35:16 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sat, 11 Jun 2011 01:35:16 +0000 (UTC) To: ding@gnus.org Original-X-From: ding-owner+M27358@lists.math.uh.edu Sat Jun 11 03:35:11 2011 Return-path: Envelope-to: ding-account@gmane.org Original-Received: from util0.math.uh.edu ([129.7.128.18]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1QVD6V-00072m-5w for ding-account@gmane.org; Sat, 11 Jun 2011 03:35:11 +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 1QVD55-0002sZ-VF; Fri, 10 Jun 2011 20:33:44 -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 1QVD53-0002sL-CC for ding@lists.math.uh.edu; Fri, 10 Jun 2011 20:33:41 -0500 Original-Received: from quimby.gnus.org ([80.91.231.51]) by mx2.math.uh.edu with esmtps (TLSv1:AES256-SHA:256) (Exim 4.76) (envelope-from ) id 1QVD51-0000nq-A8 for ding@lists.math.uh.edu; Fri, 10 Jun 2011 20:33:40 -0500 Original-Received: from static.73.179.46.78.clients.your-server.de ([78.46.179.73]) by quimby.gnus.org with esmtp (Exim 4.72) (envelope-from ) id 1QVD4z-0000hJ-EF for ding@gnus.org; Sat, 11 Jun 2011 03:33:37 +0200 Original-Received: from lee by static.73.179.46.78.clients.your-server.de with local (Exim 4.76) (envelope-from ) id 1QVD4y-0001yj-SG for ding@gnus.org; Sat, 11 Jun 2011 03:33:36 +0200 Mail-Followup-To: ding@gnus.org User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.3 (gnu/linux) X-Spam-Score: 1.6 (+) X-Spam-Report: SpamAssassin (3.3.1 2010-03-16) analysis follows Bayesian score: 0.0000 Ham tokens: 0.000-1671--6495h-0s--0d--H*UA:Emacs, 0.000-1511--5871h-0s--0d--H*u:Emacs, 0.000-1410--5478h-0s--0d--H*UA:Gnus, 0.000-1409--5477h-0s--0d--H*u:Gnus, 0.000-1354--5264h-0s--0d--H*u:linux Spam tokens: 0.965-5205--1316h-50617s--0d--H*r:quimby.gnus.org, 0.910-173--206h-2939s--0d--H*r:sk:static., 0.902-2624--3927h-50847s--0d--HX-Spam-Relays-External:quimby.gnus.org, 0.902-2624--3927h-50847s--0d--H*RU:quimby.gnus.org, 0.901-2342--3554h-45766s--0d--H*Ad:D*gnus.org Autolearn status: no -0.0 T_RP_MATCHES_RCVD Envelope sender domain matches handover relay domain 1.6 DATE_IN_PAST_03_06 Date: is 3 to 6 hours before Received: date -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] 2.0 HELO_DYNAMIC_IPADDR Relay HELO'd using suspicious hostname (IP addr 1) List-ID: Precedence: bulk Xref: news.gmane.org gmane.emacs.gnus.general:79059 Archived-At: Didier Verna writes: > lee wrote: > >> is there some sort of support built into gnus for writing articles >> (email) from templates? Such templates would contain either headers or >> a body, or a combination of both. > > So I guess you could go down this road. You can add any variable to a > topic/group parameter, for example a skeleton text. Then, what you can > do is write a message-setup-hook function that looks in there and fill > your message with the appropriate contents. > > All of this provided that group-based templating is what you have in > mind of course. Group-based templating should be fine. I would only need to specify the filename of the template text in a variable and to write a function that automatically replaces the default contents of the composing buffer with the file and then allows me to edit it :)