How to use Gnus Group Topics efficiently

  |   Source

Group Topics is used to manage Gnus groups.

For example, you can,

  • Place groups (mail folders) from Gmail into "gmail" topic
  • Place groups (mails folders) from into "hotmail" topic
  • Make "gmail" and "hotmail" belong to the root topic "Gnus"

Enable it is just one line,

(add-hook 'gnus-group-mode-hook 'gnus-topic-mode)

Now comes the question how to delete/add/move the topics?

The official answer is to read its manual.

But there is a simpler solution. All you need to do is insert below code into ~/.emacs or ~/.gnus.el,

(eval-after-load 'gnus-topic
     (setq gnus-topic-topology '(("Gnus" visible)
                                 (("hotmail" visible nil nil))
                                 (("gmail" visible nil nil))))

     (setq gnus-topic-alist '(("hotmail" ; the key of topic
                              ("gmail" ; the key of topic
                               "[Gmail]/Sent Mail"

The management of topics is as easy as editing above code.

My setup always works no matter ~/.newsrc.eld is loaded or not.

BTW, "hotmail" and "gmail" are the keys you used when configuring IMAP accounts,

(setq gnus-select-method
             '(nnimap "gmail" ; key
                      (nnimap-address "")
                      (nnimap-server-port 993)
                      (nnimap-stream ssl)))
(add-to-list 'gnus-secondary-select-methods
             '(nnimap "hotmail" ; key
                      (nnimap-address "")
                      (nnimap-server-port 993)
                      (nnimap-stream ssl)))
Comments powered by Disqus