diff options
Diffstat (limited to 'init.el')
-rw-r--r-- | init.el | 16 |
1 files changed, 13 insertions, 3 deletions
@@ -961,8 +961,18 @@ (propertize mtype 'face 'jao-themes-f01)))) (defun jao-recoll-open-html (file &optional page) - (jao-afio--goto-www) - (eww-open-file file)) + (if (string-match-p "\.epub\\'" file) + (find-file file) + (jao-afio--goto-www) + (eww-open-file file))) + +(defun jao-recoll-open-pdf (file &optional page) + (if (string-match-p "/gnus/Mail/" file) + (funcall (or (cdr (assoc-string "message/rfc822" consult-recoll-open-fns)) + 'find-file) + file + page) + (jao-open-doc file page))) (defun jao-recoll-consult-messages () (interactive) @@ -979,7 +989,7 @@ (use-package consult-recoll :init (setq consult-recoll-open-fns - '(("application/pdf" . jao-open-doc) + '(("application/pdf" . jao-recoll-open-pdf) ("text/html" . jao-recoll-open-html)) consult-recoll-search-flags nil consult-recoll-inline-snippets t |