From b7c0513998ca991c9216f0c56c5c0b31efc40400 Mon Sep 17 00:00:00 2001 From: jao Date: Sat, 18 Jun 2022 18:09:04 +0100 Subject: mailcap tweaks --- init.el | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) (limited to 'init.el') diff --git a/init.el b/init.el index 86ab5fb..312424c 100644 --- a/init.el +++ b/init.el @@ -236,6 +236,25 @@ ;;;; disk monitoring (use-package jao-dirmon :commands jao-dirmon-report) +;;;; mailcap +(use-package mailcap + :config + (add-to-list 'mailcap-mime-extensions '(".JPEG" . "image/jpeg")) + (add-to-list 'mailcap-mime-extensions '(".JPG" . "image/jpeg")) + + (defun jao-icalendar-import-buffer () + (let ((icalendar-import-format "%s%u%l%d")) + (icalendar-import-buffer diary-file t nil)) + (kill-buffer) + (message "Event imported into diary")) + + :custom + ((mailcap-user-mime-data + '((jao-icalendar-import-buffer "application/ics") + (pdf-view-mode "application/pdf" (display-graphic-p)) + ("zathura \"%s\"" "application/pdf") + (image-mode "image/*" (display-graphic-p)) + ("feh \"%s\"" "image/*"))))) ;;; Crypto ;;;; PGP, EPG, passwords (setq epg-pinentry-mode 'loopback) -- cgit v1.2.3