blob: a9ce04300033a8a64e2bfb60720593a2fc541ec7 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
|
;;; my-elfeed.el --- Configure elfeed -*- lexical-binding: t -*-
;;; Commentary:
;;; Code:
(require 'elfeed)
(require 'elfeed-org)
(with-eval-after-load 'elfeed-search
'(define-key elfeed-search-mode-map (kbd "*") 'elfeed-toggle-star))
(add-hook 'after-init-hook 'elfeed-org)
(customize-set-variable 'elfeed-search-filter "@1-month-ago +unread")
(customize-set-variable 'rmh-elfeed-org-files (list (expand-file-name "etc/elfeed.org" user-emacs-directory)))
(defalias 'elfeed-toggle-star
(elfeed-expose #'elfeed-search-toggle-all 'star))
;; set colors for some specific tags
(defface elfeed-face-tag-mustread
'((t :foreground "#f00"))
"This is a custom font face for the `mustread' tag in Elfeed."
:group 'elfeed)
(with-eval-after-load 'elfeed
(setq elfeed-search-face-alist
'((mustread elfeed-face-tag-mustread)
(unread elfeed-search-unread-title-face))))
(defun my/elfeed-show-visit-eww ()
"Visit the current entry in eww."
(interactive)
(let ((link (elfeed-entry-link elfeed-show-entry)))
(when link
(eww link))))
;; disable proportional fonts when displaying HTML content.
(advice-add #'elfeed-insert-html
:around
(lambda (fun &rest r)
(let ((shr-use-fonts nil))
(apply fun r))))
(provide 'my-elfeed)
;;; my-elfeed.el ends here
|