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,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 8926 invoked from network); 6 Nov 2020 02:14:59 -0000 Received: from mx1.math.uh.edu (129.7.128.32) by inbox.vuxu.org with ESMTPUTF8; 6 Nov 2020 02:14:59 -0000 Received: from lists1.math.uh.edu ([129.7.128.208]) by mx1.math.uh.edu with esmtps (TLS1.3) tls TLS_AES_256_GCM_SHA384 (Exim 4.94) (envelope-from ) id 1karFm-00FDbC-UW; Thu, 05 Nov 2020 20:13:26 -0600 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 1karFl-0099GE-Pt; Thu, 05 Nov 2020 20:13:25 -0600 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 1karFh-0099EP-66 for ding@lists.math.uh.edu; Thu, 05 Nov 2020 20:13:21 -0600 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 1karFf-004DKl-Cl for ding@lists.math.uh.edu; Thu, 05 Nov 2020 20:13:20 -0600 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:To:From:Sender:Reply-To:Cc:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=6x0DYErUT1lwhFYS9/728AaA1g5jInjsc9nnrl++Tn8=; b=Kv0eUli1igOyde+PXi3AEg4x2h xDTUsq2wPhOHP/Vh9uLuJC4q/a3X+Z2rkIEnMvo6LQbPXlg0CfgG2Ud9CPr+Gf9m94kmF0X/r7XSx pfxwNYNxcofKnWl+FOpD68d+MYsM/3SokF3plqd+c6iBPKqu7rppqopmPhgWv7Ws3yWY=; Received: from ericabrahamsen.net ([52.70.2.18] helo=mail.ericabrahamsen.net) by quimby.gnus.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1karFW-0004tG-J8 for ding@gnus.org; Fri, 06 Nov 2020 03:13:14 +0100 Received: from localhost (c-73-254-86-141.hsd1.wa.comcast.net [73.254.86.141]) (Authenticated sender: eric@ericabrahamsen.net) by mail.ericabrahamsen.net (Postfix) with ESMTPSA id 41203FA0B0 for ; Fri, 6 Nov 2020 02:13:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ericabrahamsen.net; s=mail; t=1604628788; bh=6x0DYErUT1lwhFYS9/728AaA1g5jInjsc9nnrl++Tn8=; h=From:To:Subject:References:Date:In-Reply-To:From; b=Bv5Acat393GA4NOQGWAG4jQdt+KKa5zmsB04866MNatb2CywYAifr5b7uo/xD0RyE thKvgTR+gQLt8sfd4NvaRspA4oHxuYfa/ZbIRPIrLPPvUzCfbXnJ98yeFYDkabc4mf 2FvcapohV0xUGSt8d1IOS2/KJDAP4Tf6fguvGbpo= From: Eric Abrahamsen To: Gnus Users Subject: Re: How to setup new nnselect group from init file? References: Date: Thu, 05 Nov 2020 18:13:05 -0800 In-Reply-To: (Pankaj Jangid's message of "Thu, 05 Nov 2020 15:57:47 +0530") Message-ID: <87361n8c7i.fsf@ericabrahamsen.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain List-ID: Precedence: bulk Pankaj Jangid writes: > I have specified messages for an nnselect group in the configuration in > ~/.gnus.el. Like this, > > (setq gnus-parameters > '(("nnselect:emacs" > (nnselect-specs > (nnselect-function . gnus-search-run-query) > (nnselect-args > (search-query-spec > (query . "recipient:emacs-devel@gnu.org")) > (search-group-spec > ("nnimap\\+codeisgreat:INBOX") > )))) > ("nnselect:postgress" > (nnselect-specs > (nnselect-function . gnus-search-run-query) > (nnselect-args > (search-query-spec > (query . "recipient:pgsql-general@lists.postgresql.org") > (query . "recipient:pgsql-announce@lists.postgresql.org") > (query . "recipient:pgsql-novice@lists.postgresql.org") > (query . "recipient:pgsql-sql@lists.postgresql.org")) This isn't going to behave the way you want. There can be only one "query" key, and the query itself will look like "recipient:pgsql-general@lists.postgresql.org or recipient:pgsql-announce@lists.postgresql.org or recipient:pgsql-novice@lists.postgresql.org..." > (search-group-spec > ("nnimap\\+codeisgreat:INBOX") > )))) > ("nnselect:cron" > (nnselect-specs > (nnselect-function . gnus-search-run-query) > (nnselect-args > (search-query-spec > (query . "from:Cron? Daemon") You'll probably want quotes around that value "from:\"Cron? Daemon\"". > (search-group-spec > ("nnml:mail.misc") > ("nnimap\\+otp:INBOX") > ))))))) > > Now how to make these groups visible in the group-buffer? I don't want > to do it in the UI. I want to set them up in the init file only. > > Other groups, like nnimap+... are automatically created once I set it up > using select method. What is the method for nnselect groups? I don't believe there's any way to create and subscribe to a group from your init files. You can certainly set parameters as above, but you'll need to create the groups from the Group buffer before the parameters take effect. That would also prevent the above incorrect search queries, since the group creation would be prompting you directly.