From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/59553 Path: main.gmane.org!not-for-mail From: =?iso-8859-1?Q?Jochen_K=FCpper?= Newsgroups: gmane.emacs.gnus.general Subject: Re: Unprintable characters Date: Mon, 10 Jan 2005 13:51:06 +0100 Organization: Fritz-Haber-Institut der MPG Message-ID: <9emzvhfnwl.fsf@gowron.rz-berlin.mpg.de> References: <87mzvhh3g2.fsf@nwalsh.com> NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha1; protocol="application/pgp-signature" X-Trace: sea.gmane.org 1105361554 12811 80.91.229.6 (10 Jan 2005 12:52:34 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 10 Jan 2005 12:52:34 +0000 (UTC) Original-X-From: ding-owner+M8093-qhrM8SXbD5ICJmmTlSVZx4dd74u8MsAO@public.gmane.org Mon Jan 10 13:52:27 2005 Return-path: Original-Received: from malifon.math.uh.edu ([129.7.128.13] ident=mail) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1Cnz23-0007lv-00 for ; Mon, 10 Jan 2005 13:52:27 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu ident=lists) by malifon.math.uh.edu with smtp (Exim 3.20 #1) id 1Cnz1D-0005rs-00; Mon, 10 Jan 2005 06:51:35 -0600 Original-Received: from util2.math.uh.edu ([129.7.128.23]) by malifon.math.uh.edu with esmtp (Exim 3.20 #1) id 1Cnz15-0005rm-00 for ding-qhrM8SXbD5ICJmmTlSVZx4dd74u8MsAO@public.gmane.org; Mon, 10 Jan 2005 06:51:27 -0600 Original-Received: from quimby.gnus.org ([80.91.224.244]) by util2.math.uh.edu with esmtp (Exim 4.30) id 1Cnz0z-0007Yg-CV for ding-qhrM8SXbD5ICJmmTlSVZx4dd74u8MsAO@public.gmane.org; Mon, 10 Jan 2005 06:51:21 -0600 Original-Received: from duras.rz-berlin.mpg.de ([141.14.130.154]) by quimby.gnus.org with esmtp (Exim 3.35 #1 (Debian)) id 1Cnz0x-0000EI-00 for ; Mon, 10 Jan 2005 13:51:19 +0100 Original-Received: from localhost (unknown [127.0.0.1]) by duras.rz-berlin.mpg.de (Postfix) with ESMTP id 49B4FED361 for ; Mon, 10 Jan 2005 13:51:10 +0100 (CET) Original-Received: from duras.rz-berlin.mpg.de ([127.0.0.1]) by localhost (duras [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 00300-01 for ; Mon, 10 Jan 2005 13:51:03 +0100 (CET) Original-Received: from gowron.rz-berlin.mpg.de.fhi-berlin.mpg.de (gowron.RZ-Berlin.MPG.DE [141.14.130.77]) by duras.rz-berlin.mpg.de (Postfix) with ESMTP id BD025ED050 for ; Mon, 10 Jan 2005 13:51:02 +0100 (CET) Original-To: ding-smP1P7uqpqc@public.gmane.org In-Reply-To: <87mzvhh3g2.fsf-wnzGKDmzZYLQT0dZR+AlfA@public.gmane.org> (Norman Walsh's message of "Mon, 10 Jan 2005 07:30:05 -0500") User-Agent: No Gnus v0.3 Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAMFBMVEUcGRSqioSCPi7Cwbxu Vk5MQjycXkxMKiQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFG2qEAAAB5klEQVR42nXUwY7aMBAA UK8E4tqpI/fMKIWzFdBewcwm10WA9tpksz6zFci/37GdxF7a+mLwi2fGQ4yo/jPE9AkaIcRM/gU7 EcfTA/zgtWsuEfRmWPVjlsOryMYpAYgvYz9B8RXmhxHEw/gcQD+sz/cDbMLXhbu7a6j6Nob6FuDW U21+uje8nuUA/rnXxR4ArCWi5jhWJSJUmoWop7HckPt+Bz6PsrYmexgg5HY3CDvKuq/lAM9hB4VQ HfZEMt8xj2BLSrD1cDlThNJMoXSEWnroDJr3HM5nDtUbRIPuluDqLlx8YdYuh0o87S6+DWANUrn+ Pf0eO7vh1Awf98XKXi/jAatnCwU/Bebl5pZqjRNs2xa4IcoqdEuN5QSbFn3pYLkqqbtyLLfSEbQi XEn4jsvpZRiAO7UCUCYBhE7zhAgSclAyToiSO5xgA+8RONYqD6X3YYdWnakJU1WVPsaI0LXU5VBF kMr6aJTBPk4KfP5SJoAYEXpE5/4FVnVrpHQ/tny/pAduZl/bBDsGLbkqD7ZN0PgbCfwucPL49gzd pZmPw22SoPoc+iZkAL+J6nRrdQEHf+4Qqm4TFJJ8idxYrumY/QEAFHQI65xhcZqgOEHhTAhk6WUu jgPohnc4wgD21+zN+c79AZmNym6Cgz4IAAAAAElFTkSuQmCC X-Archive: encrypt X-Attribution: Jochen OpenPGP: id=CC1B0B4D; url=http://jochen-kuepper.de/computer/keys.asc X-Request-PGP: http://jochen-kuepper.de/computer/keys.asc X-URL: http://jochen-kuepper.de Original-Lines: 92 X-Virus-Scanned: by amavisd-new (PP&B) at duras Precedence: bulk Original-Sender: ding-owner-qhrM8SXbD5ICJmmTlSVZx4dd74u8MsAO@public.gmane.org Xref: main.gmane.org gmane.emacs.gnus.general:59553 X-Report-Spam: http://spam.gmane.org/gmane.emacs.gnus.general:59553 --=-=-= Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Norman Walsh writes: > Additionally, is there any way to process-mark a bunch of articles and > then have them each individually forwarded to a particular address? I send them as a digest instead of individual messages, but here we go: ,---- | (defvar jk/spam-report-address "spam@somewhere" | "Email-address to report ill-classified spam.") | (defvar jk/ham-report-address "nospam@somewhere" | "Email-address to report ill-classified ham.") | (defvar jk/spam-target "nnimap+some:spam/misc" | "Group to move reported spam too.") |=20 | (defun jk/ham-spam-report (to-address) | "Digest and forward all articles in this series to the specified addres= s." | (let | ((gnus-uu-digest-headers nil) | (gnus-uu-save-in-digest t) | (file (mm-make-temp-file (nnheader-concat gnus-uu-tmp-dir "spam-re= port"))) | (message-forward-as-mime t) | (mail-parse-charset gnus-newsgroup-charset) | (mail-parse-ignored-charsets gnus-newsgroup-ignored-charsets) | gnus-uu-digest-buffer subject from) | (let ((gnus-article-reply (gnus-summary-work-articles nil))) | (gnus-setup-message 'forward | (setq gnus-uu-digest-from-subject nil) | (setq gnus-uu-digest-buffer | (gnus-get-buffer-create " *gnus spam-report*")) | (gnus-uu-decode-save nil file) | (switch-to-buffer gnus-uu-digest-buffer) | (let ((message-forward-decoded-p t)) | (message-forward nil t)))) | (setq gnus-uu-digest-from-subject nil) | ;; Ok, finish mail | ;; Subject: | (goto-char (point-min)) | (when (re-search-forward "^Subject: ") | (delete-region (point) (point-at-eol)) | (insert "ham/spam report")) | ;; From: (Heinz only accepts reports from internal address) | (goto-char (point-min)) | (when (re-search-forward "^From:") | (delete-region (point) (point-at-eol)) | (insert " jochen-xIDITz2oXuw@public.gmane.org")) | ;; Reply-To: (Heinz only accepts reports from internal address) | (goto-char (point-min)) | (when (re-search-forward "^Reply-To:" (point-max) t) | (delete-region (point) (point-at-eol)) | (insert " jochen-xIDITz2oXuw@public.gmane.org")) | ;; To: | (goto-char (point-min)) | (when (re-search-forward "^To:") | (delete-region (point) (point-at-eol)) | (insert " " to-address)) | ;; Gcc | (goto-char (point-min)) | (when (re-search-forward "^Gcc:" (point-max) t) | (delete-region (point-at-bol) (point-at-eol)) | (insert "Gcc: nnimap+some:sent/" (format-time-string "%Y/%m") | " nnimap+some:spam/reported")) | ;; remove signature | (when (message-goto-signature) | (delete-region (- (point) 4) (point-max))) | ;; and send | (message-send-and-exit))) |=20 | (defun jk/ham-report () | "Digest and forward all articles in this series to nospam@somewhere." | (interactive) | (jk/ham-spam-report jk/ham-report-address)) |=20 | (defun jk/spam-report () | "Digest and forward all articles in this series to spam@somewhere. | In addition move the marked articles to a different group (specified in | `jk/spam-target')." | (interactive) | (gnus-summary-save-process-mark) | (jk/ham-spam-report jk/spam-report-address) | (gnus-summary-yank-process-mark) | (gnus-summary-move-article nil jk/spam-target)) `---- Some more minor features, but it should work for you as well. Greetings, Jochen --=20 Einigkeit und Recht und Freiheit http://www.Jochen-Kuepper.de Libert=E9, =C9galit=E9, Fraternit=E9 GnuPG key: CC1B0B4D (Part 3 you find in my messages before fall 2003.) --=-=-= Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (GNU/Linux) iD8DBQBB4no97eYXdswbC00RAsI7AJ9H2fmuZEoUUZDIJi53lNj5C+G5gQCfQ+wG c36q1foQ+jPfBJbT+RQdj34= =PnEu -----END PGP SIGNATURE----- --=-=-=--