summaryrefslogtreecommitdiff
path: root/lisp/gnus/gnus-registry.el
diff options
context:
space:
mode:
Diffstat (limited to 'lisp/gnus/gnus-registry.el')
-rw-r--r--lisp/gnus/gnus-registry.el27
1 files changed, 15 insertions, 12 deletions
diff --git a/lisp/gnus/gnus-registry.el b/lisp/gnus/gnus-registry.el
index 147550d8cf3..0468d72edd0 100644
--- a/lisp/gnus/gnus-registry.el
+++ b/lisp/gnus/gnus-registry.el
@@ -88,7 +88,6 @@
(require 'gnus-art)
(require 'gnus-util)
(require 'nnmail)
-(require 'easymenu)
(require 'registry)
(defvar gnus-adaptive-word-syntax-table)
@@ -320,9 +319,12 @@ Encode names if ENCODE is non-nil, otherwise decode."
(setf (oref db tracked)
(append gnus-registry-track-extra
'(mark group keyword)))
- (when (not (equal old (oref db tracked)))
+ (when (not (seq-set-equal-p old (oref db tracked)))
(gnus-message 9 "Reindexing the Gnus registry (tracked change)")
- (registry-reindex db))
+ (let ((message-log-max (if (< gnus-verbose 9)
+ nil
+ message-log-max)))
+ (registry-reindex db)))
(gnus-registry--munge-group-names db)))
db)
@@ -813,7 +815,7 @@ Consults `gnus-registry-ignored-groups' and
(defun gnus-registry-wash-for-keywords (&optional force)
"Get the keywords of the current article.
Overrides existing keywords with FORCE set non-nil."
- (interactive)
+ (interactive nil gnus-article-mode gnus-summary-mode)
(let ((id (gnus-registry-fetch-message-id-fast gnus-current-article))
word words)
(if (or (not (gnus-registry-get-id-key id 'keyword))
@@ -1039,13 +1041,15 @@ Uses `gnus-registry-marks' to find what shortcuts to install."
(defun gnus-registry-set-article-mark (&rest articles)
"Apply a mark to process-marked ARTICLES."
- (interactive (gnus-summary-work-articles current-prefix-arg))
+ (interactive (gnus-summary-work-articles current-prefix-arg)
+ gnus-article-mode gnus-summary-mode)
(gnus-registry-set-article-mark-internal (gnus-registry-read-mark)
articles nil t))
(defun gnus-registry-remove-article-mark (&rest articles)
"Remove a mark from process-marked ARTICLES."
- (interactive (gnus-summary-work-articles current-prefix-arg))
+ (interactive (gnus-summary-work-articles current-prefix-arg)
+ gnus-article-mode gnus-summary-mode)
(gnus-registry-set-article-mark-internal (gnus-registry-read-mark)
articles t t))
@@ -1069,7 +1073,8 @@ Uses `gnus-registry-marks' to find what shortcuts to install."
"Get the Gnus registry marks for ARTICLES and show them if interactive.
Uses process/prefix conventions. For multiple articles,
only the last one's marks are returned."
- (interactive (gnus-summary-work-articles 1))
+ (interactive (gnus-summary-work-articles 1)
+ gnus-article-mode gnus-summary-mode)
(let* ((article (last articles))
(id (gnus-registry-fetch-message-id-fast article))
(marks (when id (gnus-registry-get-id-key id 'mark))))
@@ -1288,16 +1293,14 @@ from your existing entries."
(registry-reindex db)
(cl-loop for k being the hash-keys of (oref db data)
using (hash-value v)
- do (let ((newv (delq nil (mapcar #'(lambda (entry)
- (unless (member (car entry) extra)
- entry))
+ do (let ((newv (delq nil (mapcar (lambda (entry)
+ (unless (member (car entry) extra)
+ entry))
v))))
(registry-delete db (list k) nil)
(gnus-registry-insert db k newv)))
(registry-reindex db))))
-;; TODO: a few things
-
(provide 'gnus-registry)
;;; gnus-registry.el ends here