commit 67fe6802966ec6b47912fad5111d55f204cb4005 parent 107a0ccd37017166c423fb899ecb4245f42d56f2 Author: Vincent Demeester <vincent@sbr.pm> Date: Fri, 8 Jul 2022 16:14:18 +0200 tools/emacs: add org elfeed link support Signed-off-by: Vincent Demeester <vincent@sbr.pm> Diffstat:
M | tools/emacs/config/config-elfeed.el | | | 14 | +++++++++++++- |
1 file changed, 13 insertions(+), 1 deletion(-)
diff --git a/tools/emacs/config/config-elfeed.el b/tools/emacs/config/config-elfeed.el @@ -12,9 +12,21 @@ elfeed-db-directory "~/sync/elfeed/db/" elfeed-db-index "~/sync/elfeed/index") (elfeed-org) + (defun vde/org-elfeed-entry-store-link () + (when elfeed-show-entry + (let* ((link (elfeed-entry-link elfeed-show-entry)) + (title (elfeed-entry-title elfeed-show-entry))) + (org-store-link-props + :link link + :description title) + ))) + + (add-hook 'org-store-link-functions + 'vde/org-elfeed-entry-store-link) (use-package elfeed-org + :command (elfeed-org) :config - (setq-default rmh-elfeed-org-files (list (expand-file-name "feeds.org" org-notes-dir))))) + (setq-default rmh-elfeed-org-files (list (expand-file-name "feeds.org" org-private-notes-dir))))) (provide 'config-elfeed) ;;; config-elfeed.el ends here