summaryrefslogtreecommitdiff
path: root/elfeed-conf.el
diff options
context:
space:
mode:
Diffstat (limited to 'elfeed-conf.el')
-rw-r--r--elfeed-conf.el14
1 files changed, 14 insertions, 0 deletions
diff --git a/elfeed-conf.el b/elfeed-conf.el
index 61e43a9..94c6f72 100644
--- a/elfeed-conf.el
+++ b/elfeed-conf.el
@@ -37,6 +37,8 @@
(list "https://protesilaos.com/politics.xml"
'prot 'politics)))
+(define-key elfeed-search-mode-map (vector #x78) 'elfeed-search-exit)
+
;; I still prefer the defaults.
(setq elfeed-show-entry-switch #'switch-to-buffer)
@@ -56,5 +58,17 @@
((one-window-p))
((delete-window (get-buffer-window (current-buffer))))))
+;;;###autoload
+(defun elfeed-search-exit ()
+ "Save the database, then kill all related buffers."
+ (interactive)
+ (elfeed-db-save)
+ (mapc
+ (function
+ (lambda (buffer)
+ (cond ((string-match-p "^\\*elfeed" (buffer-name buffer))
+ (kill-buffer buffer)))))
+ (buffer-list)))
+
(provide 'elfeed-conf)
;;; elfeed-conf.el ends here