summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lisp/init-files.el9
1 files changed, 9 insertions, 0 deletions
diff --git a/lisp/init-files.el b/lisp/init-files.el
index 104ca44..ddfa001 100644
--- a/lisp/init-files.el
+++ b/lisp/init-files.el
@@ -7,6 +7,15 @@
(setq require-final-newline t
ffap-machine-p-known 'reject)
+(after 'mailcap
+ (mailcap-parse-mailcaps)
+ (pcase-dolist (`(_ . ,info)
+ (cdr (assoc-string "application" mailcap-mime-data)))
+ ;; Instead of deleting doc-view-mode entry, just make its test
+ ;; always fail.
+ (when (eq (cdr (assq 'viewer info)) 'doc-view-mode)
+ (setf (cdr (assq 'test info)) (lambda (&rest _) nil)))))
+
(defun km/rename-current-buffer-file ()
"Rename current buffer and file it is visiting."
(interactive)