From f0bfa75c969fbb09fd000932ea1b10b2d7ba724a Mon Sep 17 00:00:00 2001 From: fpi Date: Sun, 20 Dec 2020 13:35:24 +0100 Subject: Make gnus articles use prose-mode --- gnus.org | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/gnus.org b/gnus.org index aebf113..996a1c0 100644 --- a/gnus.org +++ b/gnus.org @@ -411,6 +411,11 @@ See [[info:gnus#Window Layout][info:gnus#Window Layout]]. #+begin_src emacs-lisp (setq gnus-use-full-window nil) #+end_src +**** Article Display +#+begin_src emacs-lisp +(use-package gnus-art + :hook (gnus-article-mode . prose-mode)) +#+end_src **** Modeline indicator From the [[https://www.emacswiki.org/emacs/GnusNotify][emacswiki Gnus Notify]]. #+begin_quote -- cgit v1.2.3 From 84b92d9a7b3638f9afa6db822c18b350c26126b4 Mon Sep 17 00:00:00 2001 From: fpi Date: Sat, 19 Dec 2020 18:36:30 +0100 Subject: Add symlinks for gnus state files --- gnus.org | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/gnus.org b/gnus.org index 996a1c0..d3dc7c3 100644 --- a/gnus.org +++ b/gnus.org @@ -4,7 +4,14 @@ ln -siv $(pwd)/tangle/gnus.el ~/.gnus.el #+end_src -Load private settings +I use =nextcloud= to synchronize gnus state files across devices. Alternatively one may use [[info:gnus#The Gnus Cloud][info:gnus#Gnus Cloud]]. Here i symlink the relevant files/directories to my synchronization directory. +#+begin_src shell :results silent :tangle tangle/symlink.sh :shebang "#!/bin/bash" +ln -siv ~/sync/gnus/News ~/News +ln -siv ~/sync/gnus/.newsrc.eld ~/.newsrc.eld +ln -siv ~/sync/gnus/.gnus.registry.eieio ~/.gnus.registry.eieio +#+end_src + +Load private settings. #+begin_src emacs-lisp (setq secret-file (expand-file-name "emacs-private.el.gpg" user-emacs-directory)) -- cgit v1.2.3 From ee59296fb919806374eb9d1a3eba2d2d895bfc73 Mon Sep 17 00:00:00 2001 From: fpi Date: Mon, 4 Jan 2021 15:50:51 +0100 Subject: [WIP] Add local maildir --- gnus.org | 27 ++++++++++++++++++++++----- 1 file changed, 22 insertions(+), 5 deletions(-) diff --git a/gnus.org b/gnus.org index d3dc7c3..6f069f8 100644 --- a/gnus.org +++ b/gnus.org @@ -55,19 +55,36 @@ Noweb the primary server settings together. )) #+end_src -Setup a secondary imap server and a local nntp server I use to fetch -RSS/Atom Feeds asynchronously. +To avoid confusion I enable namespaces for imap groups. +#+begin_src emacs-lisp +(setq nnimap-use-namespaces t) +#+end_src +*** Secondary servers #+begin_src emacs-lisp +<> +#+end_src +**** Personal mailbox +#+begin_src emacs-lisp :tangle no :noweb-ref secondary-select-methods (add-to-list 'gnus-secondary-select-methods `(nnimap ,@private/personal-imap-info (nnimap-stream ssl) (nnir-search-engine imap) (nnimap-inbox "INBOX"))) +#+end_src +**** RSS/Atom over nntp +Setup a secondary imap server and a local nntp server I use to fetch +RSS/Atom Feeds asynchronously. +#+begin_src emacs-lisp :tangle no :noweb-ref secondary-select-methods (add-to-list 'gnus-secondary-select-methods '(nntp "localhost" 4321)) -<> #+end_src -#+begin_src emacs-lisp -(setq nnimap-use-namespaces t) +**** Harddrive Maildir +This is still WIP, because the =nnmaildir= backend sucks. +#+begin_src emacs-lisp :tangle no +(add-to-list 'gnus-secondary-select-methods + '(nnmaildir "Local Maildir" + (directory "~/.nnmaildir") + (gnus-search-engine gnus-search-notmuch + (config-file "~/.notmuch-config")))) #+end_src ** Options *** General -- cgit v1.2.3 From ab11f2adb7b37d1ac35a1d567f802fa21279df66 Mon Sep 17 00:00:00 2001 From: fpi Date: Thu, 21 Jan 2021 16:31:17 +0100 Subject: Rename gnus group buffer --- emacs-init.org | 7 +++++++ gnus.org | 4 ++++ 2 files changed, 11 insertions(+) diff --git a/emacs-init.org b/emacs-init.org index 77a5662..d90f994 100644 --- a/emacs-init.org +++ b/emacs-init.org @@ -4253,6 +4253,13 @@ For now I use this bad code. (goto-char (point-max)) (or (bolp) (newline))))) #+END_SRC +*** Gnus +The customization for gnus is located in [[file:gnus.org][gnus.org]] and loaded from there upon startup. + +I change the group buffer to something more memorable. This needs to be set before gnus is started and therefore only setting it in gnus.org is not sufficient. +#+begin_src emacs-lisp +(setq gnus-group-buffer "*Gnus*") +#+end_src ** Footnote Mode #+begin_src emacs-lisp (use-package footnote diff --git a/gnus.org b/gnus.org index 6f069f8..c2a47c3 100644 --- a/gnus.org +++ b/gnus.org @@ -370,6 +370,10 @@ Unicode reply symbol #+begin_src emacs-lisp (setq gnus-summary-to-prefix "→ ") #+end_src +Rename the group buffer to something more memorable. This is not intended to be customized. So some bugs may occur. So far it only seems important to set it before starting gnus the first time. So e.g. set it in your main emacs =init.el=. +#+begin_src emacs-lisp +(setq gnus-group-buffer "*Gnus*") +#+end_src **** On threads Gather loose threads, whose parent is currently not displayed, under a dummy article. I find the default ~'adopt~ to be too confusing. -- cgit v1.2.3 From 02c605d87e2b97955c2e8b3fe737f8615cfb4b83 Mon Sep 17 00:00:00 2001 From: fpi Date: Wed, 27 Jan 2021 11:00:07 +0100 Subject: Make scoring section more generic --- gnus.org | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/gnus.org b/gnus.org index c2a47c3..1a7f454 100644 --- a/gnus.org +++ b/gnus.org @@ -171,8 +171,20 @@ Background fetching for gnus. See the manual and [[https://www.emacswiki.org/ema (gnus-demon-add-handler 'gnus-demon-scan-news-4 130 1) (gnus-demon-add-handler 'gnus-demon-scan-news-5 140 1) #+end_src -**** Adaptive scoring -See [[info:gnus#Adaptive Scoring][info:gnus#Adaptive Scoring]] and this [[https://notes.whatthefuck.computer/1417593600.0-note.html][blog post]] by Ryan Rix. +**** Scoring +To define different scoring files for different groups I set [[info:gnus#Home Score File][home score files]] based on the group name. +#+begin_src emacs-lisp +(setq gnus-home-score-file + '(("^nnimap" "nnimap.SCORE") ;; w/ author scoring + ("gmane" "nntp_gmane.SCORE") ;; w/ author scoring + ("^nntp\\+localhost" "nntp_global.SCORE") ;; w/o author scoring + )) +(setq gnus-home-adapt-file + '(("^nnimap" "nnimap.ADAPT") + ("gmane" "nntp_gmane.ADAPT") + ("^nntp\\+localhost" "nntp_global.ADAPT"))) +#+end_src +For information about adaptive scoring see [[info:gnus#Adaptive Scoring][info:gnus#Adaptive Scoring]] and this [[https://notes.whatthefuck.computer/1417593600.0-note.html][blog post]] by Ryan Rix. ***** Score File Setup #+begin_src emacs-lisp (setq gnus-use-adaptive-scoring '(word line)) @@ -190,19 +202,7 @@ See [[info:gnus#Adaptive Scoring][info:gnus#Adaptive Scoring]] and this [[https: ) ;; (setq gnus-adaptive-word-score-alist gnus-default-adaptive-word-score-alist) #+end_src -****** Using different (adaptive) scoring files for different groups -To define different adaptive scoring files for different groups I set [[info:gnus#Home Score File][home score files]] based on the group name. -#+begin_src emacs-lisp -(setq gnus-home-score-file - '(("^nnimap" "nnimap.SCORE") ;; w/ author scoring - ("gmane" "nntp_gmane.SCORE") ;; w/ author scoring - ("^nntp\\+localhost" "nntp_global.SCORE") ;; w/o author scoring - )) -(setq gnus-home-adapt-file - '(("^nnimap" "nnimap.ADAPT") - ("gmane" "nntp_gmane.ADAPT") - ("^nntp\\+localhost" "nntp_global.ADAPT"))) -#+end_src +****** Scoring rules Scoring based on the =from= header does not make sense for rss feeds with only one author or newsgroups with unset author. These files therefore contain my default adaptive scoring rules with or without =from= scoring. #+NAME: gnus-adaptive-scoring-w-from #+begin_src emacs-lisp :tangle no :eval never @@ -245,7 +245,7 @@ Slow scoring decay prevents huge scores from building up. Only run on =.ADAPT= s gnus-score-decay-constant 1 gnus-score-decay-scale 0.01) #+end_src -****** Ignored Words +***** Ignored Words Do not score on some common german words. I extracted these from my score file after a few weeks of using scoring. #+begin_src emacs-lisp (setq gnus-ignored-adaptive-words -- cgit v1.2.3 From 053a3445ffbf21fab758bf44cc568db52d174d4d Mon Sep 17 00:00:00 2001 From: fpi Date: Sun, 31 Jan 2021 15:09:56 +0100 Subject: Keep temporary score rules for longer --- gnus.org | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/gnus.org b/gnus.org index 1a7f454..d0bc434 100644 --- a/gnus.org +++ b/gnus.org @@ -185,6 +185,11 @@ To define different scoring files for different groups I set [[info:gnus#Home Sc ("^nntp\\+localhost" "nntp_global.ADAPT"))) #+end_src For information about adaptive scoring see [[info:gnus#Adaptive Scoring][info:gnus#Adaptive Scoring]] and this [[https://notes.whatthefuck.computer/1417593600.0-note.html][blog post]] by Ryan Rix. + +Temporary scores by default expire after 7 days. I want a slightly longer threshold. +#+begin_src emacs-lisp +(setq gnus-score-expiry-days 14) +#+end_src ***** Score File Setup #+begin_src emacs-lisp (setq gnus-use-adaptive-scoring '(word line)) -- cgit v1.2.3 From f9179aa6bd96155d101ad89977c2006a39bf508f Mon Sep 17 00:00:00 2001 From: fpi Date: Sun, 20 Feb 2022 18:33:15 +0100 Subject: BCC self and use general search syntax Also remove fix for old gnus-cloud bug --- gnus.org | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/gnus.org b/gnus.org index d0bc434..dae6d1a 100644 --- a/gnus.org +++ b/gnus.org @@ -94,6 +94,11 @@ Load only groups with level < 2 for faster startup. (setq gnus-activate-level 2) #+end_src **** Message related +Bcc self to archive sent messages & ensure proper sending +#+begin_src emacs-lisp +(setq message-default-mail-headers + (format "Bcc: %s\n" user-mail-address)) +#+end_src Sent mails are read. #+begin_src emacs-lisp (setq gnus-gcc-mark-as-read t) @@ -140,6 +145,11 @@ Setup for fancy mail splitting. Also see the parameters in ~gnus-select-method~. (setq nnmail-cache-accepted-message-ids t) (setq nnmail-message-id-cache-length 10000) #+end_src +**** Search +Use gnus search language. See [[info:gnus#Search Queries][gnus#Search Queries]] for info. +#+begin_src emacs-lisp +(setq gnus-search-use-parsed-queries t) +#+end_src **** Demon Background fetching for gnus. See the manual and [[https://www.emacswiki.org/emacs/GnusDemon][emacswiki]]. #+begin_src emacs-lisp @@ -616,10 +626,6 @@ contains new messages")) ;;; gnus-notify.el ends here #+end_src *** Misc -Workaround for bug with ~gnus-cloud-method~ and ~custom-variable-recalc-variable~ upon reloading the =spacemacs-*= theme. -#+begin_src emacs-lisp -(setq server "nnimap:imsmail") -#+end_src **** nnreddit #+begin_src emacs-lisp (use-package nnreddit -- cgit v1.2.3