From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,RCVD_IN_DNSWL_LOW autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 1534 invoked from network); 25 Sep 2020 18:26:00 -0000 Received: from lists1.math.uh.edu (129.7.128.208) by inbox.vuxu.org with ESMTPUTF8; 25 Sep 2020 18:26:00 -0000 Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu) by lists1.math.uh.edu with smtp (Exim 4.94) (envelope-from ) id 1kLsPV-00GNqR-Qy; Fri, 25 Sep 2020 13:25:33 -0500 Received: from mx2.math.uh.edu ([129.7.128.33]) by lists1.math.uh.edu with esmtps (TLS1.3) tls TLS_AES_256_GCM_SHA384 (Exim 4.94) (envelope-from ) id 1kLsPR-00GNoc-RU for ding@lists.math.uh.edu; Fri, 25 Sep 2020 13:25:29 -0500 Received: from quimby.gnus.org ([95.216.78.240]) by mx2.math.uh.edu with esmtps (TLS1.3) tls TLS_AES_256_GCM_SHA384 (Exim 4.94) (envelope-from ) id 1kLsPQ-009Nzq-8R for ding@lists.math.uh.edu; Fri, 25 Sep 2020 13:25:29 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Transfer-Encoding:Content-Type:Mime-Version:References :Message-ID:Date:Subject:From:To:Sender:Reply-To:Cc:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=svYVqIhzyIGsSkh0HWXZBC+WRBMtFdnOnvfNIRBNkeg=; b=HemkmvrHTwL+s9V9Jc8RhvRa8j YSAPVyH9pQqsLs6sclCkcQS+hYrpIsJHCZY29wBXBDS9g1NfjYWLcjqUQm+i/wrZn2VJ8O6rQXDxl yhcyLIRkNk2xZU4WkKfePoDj0bG75z6rELA18LNtWtZPKy3noO6Vycgz+Q4+AIz0EiTQ=; Received: from static.214.254.202.116.clients.your-server.de ([116.202.254.214] helo=ciao.gmane.io) by quimby with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kLsPJ-0005FR-NJ for ding@gnus.org; Fri, 25 Sep 2020 20:25:23 +0200 Received: from list by ciao.gmane.io with local (Exim 4.92) (envelope-from ) id 1kLsPH-0000RQ-T3 for ding@gnus.org; Fri, 25 Sep 2020 20:25:19 +0200 X-Injected-Via-Gmane: http://gmane.org/ To: ding@gnus.org From: =?utf-8?Q?Adam_Sj=C3=B8gren?= Subject: Re: Does Gnus automatically run 'notmuch new' if configured? Date: Fri, 25 Sep 2020 20:25:15 +0200 Organization: koldfront - analysis & revolution, Copenhagen, Denmark Message-ID: <87o8lt1zp0.fsf@tullinup.koldfront.dk> References: <875z83njo0.fsf@tullinup.koldfront.dk> <87o8luz39v.fsf@ucl.ac.uk> <87o8lukxsm.fsf@tullinup.koldfront.dk> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cancel-Lock: sha1:lcF1NaSjHyi+Ry3bd+7B7KIknNg= OpenPGP: id=476630590A231909B0A0961A49D0746121BDE416; url=https://asjo.koldfront.dk/gpg.asc Mail-Follow-Up-To: never X-Face: )qY&CseJ?.:=8F#^~GcSA?F=9eu'{KAFfL1C3/A&:nE?PW\i65"ba0NS)97,Q(^@xk}n4Ou rPuR#V8I(J_@~H($[ym:`K_+]*kjvW>xH5jbgLBVFGXY:(#4P>zVBklLbdL&XxL\M)%T}3S/IS9lMJ ^St'=VZBR Precedence: bulk Adam writes: > But now this discussion makes me want to have it in a hook... In case anyone cares/for reference, here is what I ended up with in my .emacs, inspired by this thread: (defun asjo-notmuch-new () "Run notmuch new" (start-process "notmuch" "*Notmuch*" "notmuch" "new")) (defadvice gnus (after gnus-notmuch-new activate) (asjo-notmuch-new)) and in my .gnus: (add-hook 'gnus-after-getting-new-news-hook 'asjo-notmuch-new) I think this is nicer than the cron job, even though the advice feels hacky. Never again shall I think "Oh, maybe it wasn't in the search results because the index isn't up to date"! Best regards, Adam -- "The key to performance is elegance, not battalions Adam Sjøgren of special cases." asjo@koldfront.dk