From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.user/4467 Path: news.gmane.org!not-for-mail From: Reiner Steib Newsgroups: gmane.emacs.gnus.user Subject: Re: Concat signatures. Date: Fri, 11 Feb 2005 14:49:13 +0100 Organization: Dept. of Theoretical Physics, University of Ulm Message-ID: References: Reply-To: Reiner Steib NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Trace: sea.gmane.org 1138670374 23348 80.91.229.2 (31 Jan 2006 01:19:34 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 31 Jan 2006 01:19:34 +0000 (UTC) Original-X-From: nobody Tue Jan 17 17:33:49 2006 Original-Newsgroups: gnu.emacs.gnus X-Face: P05mdcZT&lL[-s2=mw~RsllZ0zZAb?vdE}.s On Fri, Feb 11 2005, François LAGARDE wrote: > I would like to concat differents signature-file in my > posting-style. Ideally I would lile something like that: > (setq gnus-posting-styles > '((".*" > (signature (concat "my_first_file" "my_second_file"))) > (".*afield.*" > (signature (concat "my_first_file" "my_third_file"))) > ) > ) > > Any idea. (defun rs-gnus-signature-files-to-string (&rest files) "Concat FILES and return a string." (with-temp-buffer (dolist (f files) (insert-file-contents f)) ;; Borrowed from `gnus-configure-posting-styles': (buffer-substring (point-min) (progn (goto-char (point-max)) (if (zerop (skip-chars-backward "\n")) (point) (1+ (point))))))) (setq gnus-posting-styles `((".*" (signature ,(rs-gnus-signature-files-to-string "my_first_file" "my_second_file"))) (".*test.*" (signature ,(rs-gnus-signature-files-to-string "my_first_file" "my_third_file"))))) Bye, Reiner. -- ,,, (o o) ---ooO-(_)-Ooo--- | PGP key available | http://rsteib.home.pages.de/