From 5737b2e30e805af7b3d527b9547e08e14410e102 Mon Sep 17 00:00:00 2001 From: jao Date: Mon, 19 Jul 2021 21:13:10 +0100 Subject: lexical binding for gnus.el --- gnus.org | 36 +++++++++++++++++++----------------- 1 file changed, 19 insertions(+), 17 deletions(-) (limited to 'gnus.org') diff --git a/gnus.org b/gnus.org index 79f19df..9f1d545 100644 --- a/gnus.org +++ b/gnus.org @@ -1,4 +1,4 @@ -#+property: header-args :tangle ~/.emacs.d/gnus.el :comments yes :results silent +#+property: header-args :lexical t :tangle ~/.emacs.d/gnus.el :comments yes :results silent :shebang ";; -*- lexical-binding: t -*-" :tangle-mode (identity #o644) #+title: Gnus #+auto_tangle: t @@ -217,11 +217,12 @@ (defvar jao-gnus-tracked-groups '(("nnimap:bigml/inbox" "B" jao-themes-f00) - ("nnselect:.*bugs" "b" jao-themes-error) + ("nnselect:bigml-bugs" "b" jao-themes-error) ("nnimap:bigml/support" "S" default) ("nnimap:jao/inbox" "I" jao-themes-f01) ("nnimap:bigml/[^ibs]" "W" jao-themes-dimm) ("nnimap:jao" "J" jao-themes-dimm) + ("nnimap:local" "l" jao-themes-dimm) ("nnimap:feeds/[^e]" "F" jao-themes-dimm) ("^gmane\\.emacs\\|nnimap:feeds/emacs" "E" jao-themes-dimm) ("^gmane\\.[^e]\\|^gwene" "N" jao-themes-dimm))) @@ -245,8 +246,8 @@ (defun jao-gnus--notify-strs () (let ((counts (jao-gnus--unread-counts))) (seq-filter #'identity - (seq-map `(lambda (args) - (apply 'jao-gnus--unread-label ',counts args)) + (seq-map (lambda (args) + (apply 'jao-gnus--unread-label counts args)) jao-gnus-tracked-groups)))) (defun jao-gnus--notify () @@ -389,16 +390,7 @@ #+end_src * Group parameters #+begin_src emacs-lisp - (setq jao-gnus-expirable - (format (concat "^nnimap:\\(" - "\\(bigml/%s\\)\\|" - "\\(jao/%s\\)\\|" - "\\(feeds/.*\\)\\|trash\\|spam\\|local" - "\\)") - (regexp-opt '("reports" "deploys" "lists" "drivel" "bugs")) - (regexp-opt '("think" "drivel" "lists")))) - - (setq gnus-permanently-visible-groups "^nnselect:.*today") + (setq gnus-permanently-visible-groups "^nnselect:.*-today") (setq gnus-parameters `(("^nnimap:jao/.*" @@ -415,6 +407,7 @@ ("^nnimap:.*/\\(inbox\\|hacking\\)" (gcc-self . t)) ("^nnimap:bigml/.*" + (gcc-self . t) (posting-style (address "jao@bigml.com")) (jao-gnus--archiving-group "nnimap:bigml/trove") (jao-gnus--spam-group "nnimap:bigml/spam")) @@ -425,20 +418,29 @@ (expiry-target . "nnimap:bigml/trove")) ("^nnimap:bigml/support" (posting-style (address "support@bigml.com"))) - (,jao-gnus-expirable + (,(format "^nnimap:bigml/%s" + (regexp-opt '("reports" "deploys" "lists" "drivel"))) (jao-gnus--trash-group nil) (gcc-self . nil) (auto-expire . t) (total-expire . t) (expiry-wait . 3) (expiry-target . delete)) + ("^nnimap:\\(jao/\\(think\\|drivel\\)\\|local\\)" + (auto-expire . t) + (total-expire . t) + (expiry-wait . 1) + (expiry-target . delete)) ("^nnimap:feeds/.*" + (auto-expire . t) + (total-expire . t) + (expiry-wait . 7) + (expiry-target . delete) (jao-gnus--archiving-group "nnimap:feeds/trove")) + ("^nnimap:feeds/news$" (expiry-wait . 1)) ("^nnimap:feeds/trove" (auto-expire . nil) (total-expire . nil)) - ("^nnimap:feeds/\\(papers\\|math\\|physics\\)$" - (expiry-wait . 30)) ("\\(gmane\\|gwene\\)\\..*" (jao-gnus--archiving-group "nnimap:feeds/trove") (posting-style (address "jao@gnu.org"))))) -- cgit v1.2.3