From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/12951 Path: main.gmane.org!not-for-mail From: Urban Engberg Newsgroups: gmane.emacs.gnus.general Subject: Hooking on to new messages Date: 25 Nov 1997 09:16:34 +0100 Message-ID: NNTP-Posting-Host: coloc-standby.netfonds.no Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Trace: main.gmane.org 1035152399 6556 80.91.224.250 (20 Oct 2002 22:19:59 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Sun, 20 Oct 2002 22:19:59 +0000 (UTC) Return-Path: Original-Received: from xemacs.org (xemacs.cs.uiuc.edu [128.174.252.16]) by altair.xemacs.org (8.8.8/8.8.8) with ESMTP id BAA03736 for ; Tue, 25 Nov 1997 01:26:50 -0800 Original-Received: from ifi.uio.no (ifi.uio.no [129.240.64.2]) by xemacs.org (8.8.5/8.8.5) with ESMTP id DAA13910 for ; Tue, 25 Nov 1997 03:26:48 -0600 (CST) Original-Received: from claymore.vcinet.com (claymore.vcinet.com [208.205.12.23]) by ifi.uio.no (8.8.8/8.8.7/ifi0.2) with SMTP id JAA13386 for ; Tue, 25 Nov 1997 09:16:33 +0100 (MET) Original-Received: (qmail 7581 invoked by uid 504); 25 Nov 1997 08:16:25 -0000 Original-Received: (qmail 7578 invoked from network); 25 Nov 1997 08:16:25 -0000 Original-Received: from ns.cci.dk (194.239.27.66) by claymore.vcinet.com with SMTP; 25 Nov 1997 08:16:24 -0000 Original-Received: from gatekeeper.cci.dk by ns.cci.dk with smtp (Smail3.1.29.1 #58) id m0xaGB4-000Rj7C; Tue, 25 Nov 97 09:17 MET Original-Received: from ue. by gatekeeper.cci.dk with smtp (Smail3.1.29.1 #61) id m0xaG16-0002nSC; Tue, 25 Nov 97 09:06 MET Original-Received: by ue. (SMI-8.6/SMI-SVR4) id JAA07188; Tue, 25 Nov 1997 09:16:35 +0100 Original-To: ding@gnus.org Original-Lines: 28 X-Mailer: Quassia Gnus v0.14/Emacs 20.2 Xref: main.gmane.org gmane.emacs.gnus.general:12951 X-Report-Spam: http://spam.gmane.org/gmane.emacs.gnus.general:12951 I am trying to make Gnus notify me whenever there is new mail, but only when it's personal. I don't want to use procmail, so I use Gnus' mail-splitting (nnmail-split-fancy) and add a mail scanning daemon like this: (gnus-demon-add-handler 'gnus-demon-scan-mail 1 nil) Now, to detect when there is some interesting mail, I have tried (add-hook 'nnml-prepare-save-mail-hook 'ue-gnus-article-notify) (or alternatively nnmail-prepare-save-mail-hook). ue-gnus-article-notify should thus get called on each new message, and may for instance look for the new X-ref header and produce some sort of notification when I want it to. The strange thing is that this seems to work most of the time -- when I am actively working inside Emacs, that is. When I leave Emacs for some time, I can see that gnus-demon-scan-mail gets called as it should every minute, but ue-gnus-article-notify is never being called. I've tried to debug, but without success (as I said, when I am working in Emacs, it seems to work). Am I using the right hook? Some better way to do this? Urban -- ue * 105