On Tue, Dec 16 2025, Xiyue Deng <[email protected]> wrote:

> Hi,

> I have been using nnmaildir together with offlineimap and notmuch for
> my Gmail and Outlook email accounts.  This turns out to work
> reasonably well (even though slower than notmuch.el but bearable.)
> However a small annoyance is that nnmaildir does not subscribe to the
> Gmail specific folders by default, e.g. "[Gmail].Sent Mail",
> "[Gmail].Spam", etc.  With some initial digging I found that they are
> given group level 9 which I think is the reason.

> I then tried to use `gnus-subscribe-group' to manually subscribe them.
> This kind of worked and those folders did show up in the topic buffer.
> But then they are not scanned for new messages by default until
> I manually checked them (by hitting RET on each one.) And this state
> is reset next time I launch Gnus, which is cumbersome.

> Note that this is happening on nnmaildir backend.  When using nnimap
> those folders are subscribed by default, which I think means that they
> are given a lower group level value in nnimap.

> So I wonder how a group level is determined in nnmaildir and why it's
> different than in nnimap?  Hopefully this can help me understand the
> internals of Gnus better so that I can change the settings to meet my
> expectations better.

> Thanks in advance!

It happened to me even on ‘nnimap’, after the ‘newsrc.eld’
corruption[¹], I lost all the groups.  But, after a quitting and
re-starting Gnus, it found the groups but subscribed as killed groups.
However, setting their subscription level interactively (with
‘gnus-group-set-current-level’ bound to ‘S l’) worked and remained
intact (their subscription level is saved in ‘newsrc.eld’ file), and the
groups were scanned for new messages.

If you want the new found groups to be subscribed at higher level, you
probably should check the ‘gnus-subscribe-newsgroup-method’.

Gnus manual documents that any active group has to scanned (asked from
the server for new messages).  You may try ‘gnus-activate-all-groups’
(bound to ‘C-c M-g’) to activate all groups in your ‘*group*’ buffer.
I think ‘gnus-activate-level’ and ‘gnus-activate-foreign-newsgroups’ (if
you have foreign groups) are the variables that determine if a group
should be active or not.

Gnus manual says: “Un-activated groups are listed with ‘*’ in the
group buffer.”

If it’s not the case, perhaps Gmail servers are in fault.

   ---------- Footnotes ----------

[1]  It happens to me sometimes; when the Disroot servers are down and
     Gnus tries to connect to the server, it takes too long and
     I cancel it with ‘C-g’, which corrupts the ‘newsrc.eld’ if I save
     it manually with ‘C-u s’ (which I unfortunately do).

-- 
English is not my native/mother language.  I can read and understand
English well, but I have problems expressing my thoughts in it.
Please, bear with me.  Sincerely, Pyromania.

PGP fingerprint = 2B24 291E 0637 4D2E 0D14  9EFC D7B3 10D4 5C9D 5892

()  ASCII ribbon campaign - against HTML e-mail
/\  www.asciiribbon.org   - against proprietary attachments

Attachment: signature.asc
Description: PGP signature

Reply via email to