Announcements and discussions for Gnus, the GNU Emacs Usenet newsreader
 help / color / mirror / Atom feed
From: Jarmo Hurri <jarmo.hurri@syk.fi>
To: info-gnus-english@gnu.org
Subject: Re: gnus-no-server and startup level
Date: Thu, 18 Oct 2012 09:26:17 +0300	[thread overview]
Message-ID: <876268s3cm.fsf@syk.fi> (raw)
In-Reply-To: <87mwzlp3ek.fsf@syk.fi>


> So gnus-no-server starts gnus at level 2, and that is why I do not see
> my nnfolders.

Thinking about this overnight I came up with an idea. Since
gnus-no-server needs to be started at level 2 for legacy reasons, but
there seems to be more than one person who would want it to start with
the default level setup, could we not have a boolean variable for this?
Something like

gnus-no-server-startup-level-default-subscribed-minus-1

whose default value would be t for legacy reasons. Setting this to nil
would mean that gnus-no-server would not enforce a startup level, nor
would it set gnus-group-use-permanent-levels. This would imply minor
changes in the following function; I can try to send a patch later if
need be:

;; ------------------------------------------------------------------
(defun gnus-no-server-1 (&optional arg slave)
  "Read network news.
If ARG is a positive number, Gnus will use that as the startup
level.  If ARG is nil, Gnus will be started at level 2
\(`gnus-level-default-subscribed' minus one).  If ARG is non-nil
and not a positive number, Gnus will prompt the user for the name
of an NNTP server to use.  As opposed to \\[gnus], this command
will not connect to the local server."
  (interactive "P")
  (let ((val (or arg (1- gnus-level-default-subscribed))))
    (gnus val t slave)
    (make-local-variable 'gnus-group-use-permanent-levels)
    (setq gnus-group-use-permanent-levels val)))
;; ------------------------------------------------------------------

The problem with the current "solution" - setting
gnus-level-default-subscribed - is that, first, it messes the value of
that variable and, second, gnus-group-use-permanent-levels is still set,
which affects the visibility of groups.

--

Jarmo

      parent reply	other threads:[~2012-10-18  6:26 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-17 14:41 Jarmo Hurri
2012-10-17 14:56 ` Jarmo Hurri
2012-10-17 15:47   ` Tassilo Horn
2012-10-17 17:43     ` Jarmo Hurri
2012-10-18  6:41       ` Tassilo Horn
2012-10-18  6:26 ` Jarmo Hurri [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=876268s3cm.fsf@syk.fi \
    --to=jarmo.hurri@syk.fi \
    --cc=info-gnus-english@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).