From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/68325 Path: news.gmane.org!not-for-mail From: Andreas Seltenreich Newsgroups: gmane.emacs.gnus.general Subject: Re: gnus-subscribe-topics Date: Mon, 23 Feb 2009 01:29:16 +0100 Message-ID: <8763j2uhb7.fsf@gate450.dyndns.org> References: <87y6xqn3zn.fsf@gnu.org> <87prj2u2lr.fsf@marauder.physik.uni-ulm.de> <87fxjymztn.fsf@gnu.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: ger.gmane.org 1235349044 23891 80.91.229.12 (23 Feb 2009 00:30:44 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 23 Feb 2009 00:30:44 +0000 (UTC) Cc: xavier@maillard.mobi, xma@gnu.org To: ding@gnus.org Original-X-From: ding-owner+M16765@lists.math.uh.edu Mon Feb 23 01:32:00 2009 Return-path: Envelope-to: ding-account@gmane.org Original-Received: from util0.math.uh.edu ([129.7.128.18]) by lo.gmane.org with esmtp (Exim 4.50) id 1LbOjm-00080W-Uv for ding-account@gmane.org; Mon, 23 Feb 2009 01:31:59 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu) by util0.math.uh.edu with smtp (Exim 4.63) (envelope-from ) id 1LbOhK-00017E-EG; Sun, 22 Feb 2009 18:29:26 -0600 Original-Received: from mx2.math.uh.edu ([129.7.128.33]) by util0.math.uh.edu with esmtps (TLSv1:AES256-SHA:256) (Exim 4.63) (envelope-from ) id 1LbOhI-000172-Gg for ding@lists.math.uh.edu; Sun, 22 Feb 2009 18:29:24 -0600 Original-Received: from quimby.gnus.org ([80.91.231.51]) by mx2.math.uh.edu with esmtp (Exim 4.69) (envelope-from ) id 1LbOhF-000679-7J for ding@lists.math.uh.edu; Sun, 22 Feb 2009 18:29:24 -0600 Original-Received: from smtp1.rz.uni-karlsruhe.de ([129.13.185.217] ident=Debian-exim) by quimby.gnus.org with esmtp (Exim 3.36 #1 (Debian)) id 1LbOhZ-0007IL-00 for ; Mon, 23 Feb 2009 01:29:41 +0100 Original-Received: from rzstud2.stud.uni-karlsruhe.de (rzstud2.stud.uni-karlsruhe.de [193.196.41.42]) by smtp1.rz.uni-karlsruhe.de with esmtps (Exim 4.63 #1) id 1LbOhC-0002mm-3I; Mon, 23 Feb 2009 01:29:18 +0100 Original-Received: from uwi7 by rzstud2.stud.uni-karlsruhe.de with local (Exim 4.63) (envelope-from ) id 1LbOhB-0005mI-G2; Mon, 23 Feb 2009 01:29:17 +0100 In-Reply-To: <87fxjymztn.fsf@gnu.org> (Xavier Maillard's message of "Mon, 05 Jan 2009 00:11:32 +0100") User-Agent: Gnus/5.110011 (No Gnus v0.11) Emacs/22.3 (gnu/linux) Mail-Followup-To: ding@gnus.org,xavier@maillard.mobi, andreas+ding@gate450.dyndns.org, xma@gnu.org X-Hashcash: 1:26:090222:ding@gnus.org::V+PJNopwvxv75z45:0tPBD X-Hashcash: 1:26:090222:xma@gnu.org::XmTbnHmhyHolRrHU:0r3Nt X-Hashcash: 1:26:090222:xavier@maillard.mobi::PU/W0L/4M+dFhFDL:00000000000002Z7Rv X-Spam-Score: -4.8 (----) List-ID: Precedence: bulk Xref: news.gmane.org gmane.emacs.gnus.general:68325 Archived-At: --=-=-= Xavier Maillard writes: > Reiner Steib writes: > >> ,----[ (info "(gnus)Subscription Methods") ] >> | What Gnus does when it encounters a new group is determined by the >> | `gnus-subscribe-newsgroup-method' variable. >> `---- >> >> "when it encounters a new group" is not the case in your situation. >> This variable is relevant only if a new newsgroup is created on the >> server. > > Can't this behaviour be changed for any group (new or existing > but never subscribed) ? What is the workaround ? Currently, I did > not subcribe to any nnimap groups (I have 4 dozens of them > pending) since I do not want to manually fill them under the > right topic. I've modified my copy of Gnus to use gnus-subscribe-newsgroup-method when subscribing from a Browse Server buffer a long time ago. I didn't propose to include this patch though because the default value of g-s-n-m is rather inappropriate for explicitly subscribing groups. Attached is a version that introduces a gnus-browse-subscribe-newsgroup-method variable instead. OK to commit to No Gnus? I vaguely remeber some discussion about a feature freeze (Reiner?). >>> P.S: please keep me in the Cc as I am not subscribed to this list yet. >> >> Hint: Gnus honors Mail-Followup-To. :-) > > Done (hope it is correct). The comma looks like a typo to me. You can avoid this by letting Message Mode generate the header. C-c C-f C-a runs the command message-generate-unsubscribed-mail-followup-to. regards, andreas --=-=-= Content-Type: text/x-diff Content-Disposition: inline; filename=gnus-srvr.diff Index: gnus-srvr.el =================================================================== RCS file: /usr/local/cvsroot/gnus/lisp/gnus-srvr.el,v retrieving revision 7.36 diff -c -r7.36 gnus-srvr.el *** gnus-srvr.el 22 Jan 2009 07:02:16 -0000 7.36 --- gnus-srvr.el 23 Feb 2009 00:09:45 -0000 *************** *** 635,640 **** --- 635,663 ---- ;;; Browse Server Mode ;;; + (defcustom gnus-browse-subscribe-newsgroup-method + 'gnus-subscribe-alphabetically + "Function(s) called when subscribing groups in the Browse Server Buffer + A few pre-made functions are supplied: `gnus-subscribe-randomly' + inserts new groups at the beginning of the list of groups; + `gnus-subscribe-alphabetically' inserts new groups in strict + alphabetic order; `gnus-subscribe-hierarchically' inserts new groups + in hierarchical newsgroup order; `gnus-subscribe-interactively' asks + for your decision; `gnus-subscribe-killed' kills all new groups; + `gnus-subscribe-zombies' will make all new groups into zombies; + `gnus-subscribe-topics' will enter groups into the topics that + claim them." + :group 'gnus-server + :type '(radio (function-item gnus-subscribe-randomly) + (function-item gnus-subscribe-alphabetically) + (function-item gnus-subscribe-hierarchically) + (function-item gnus-subscribe-interactively) + (function-item gnus-subscribe-killed) + (function-item gnus-subscribe-zombies) + (function-item gnus-subscribe-topics) + function + (repeat function))) + (defvar gnus-browse-menu-hook nil "*Hook run after the creation of the browse mode menu.") *************** *** 885,891 **** (gnus-browse-next-group (- n))) (defun gnus-browse-unsubscribe-current-group (arg) ! "(Un)subscribe to the next ARG groups." (interactive "p") (when (eobp) (error "No group at current line")) --- 908,916 ---- (gnus-browse-next-group (- n))) (defun gnus-browse-unsubscribe-current-group (arg) ! "(Un)subscribe to the next ARG groups. ! The variable `gnus-browse-subscribe-newsgroup-method' determines ! how new groups will be entered into the group buffer." (interactive "p") (when (eobp) (error "No group at current line")) *************** *** 934,955 **** ;; subscribe to it. (if (gnus-ephemeral-group-p group) (gnus-kill-ephemeral-group group)) ! ;; We need to discern between killed/zombie groups and ! ;; just unsubscribed ones. ! (gnus-group-change-level ! (or (gnus-group-entry group) ! (list t group gnus-level-default-subscribed ! nil nil (if (gnus-server-equal ! gnus-browse-current-method "native") ! nil ! (gnus-method-simplify ! gnus-browse-current-method)))) ! gnus-level-default-subscribed (gnus-group-level group) ! (and (car (nth 1 gnus-newsrc-alist)) ! (gnus-group-entry (car (nth 1 gnus-newsrc-alist)))) ! (null (gnus-group-entry group))) (delete-char 1) ! (insert ? )) (gnus-group-change-level group gnus-level-unsubscribed gnus-level-default-subscribed) (delete-char 1) --- 959,982 ---- ;; subscribe to it. (if (gnus-ephemeral-group-p group) (gnus-kill-ephemeral-group group)) ! (let ((entry (gnus-group-entry group))) ! (if entry ! ;; Just change the subscription level if it is an ! ;; unsubscribed group. ! (gnus-group-change-level entry ! gnus-level-default-subscribed) ! ;; If it is a killed group or a zombie, feed it to the ! ;; mechanism for new group subscription. ! (gnus-call-subscribe-functions ! gnus-browse-subscribe-newsgroup-method ! group))) (delete-char 1) ! (insert (let ((lvl (gnus-group-level group))) ! (cond ! ((< lvl gnus-level-unsubscribed) ? ) ! ((< lvl gnus-level-zombie) ?U) ! ((< lvl gnus-level-killed) ?Z) ! (t ?K))))) (gnus-group-change-level group gnus-level-unsubscribed gnus-level-default-subscribed) (delete-char 1) --=-=-=--