From e130c7984df9991e3158db02a5a54255e60c17bd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=93scar=20N=C3=A1jera?= Date: Tue, 11 Oct 2022 05:12:31 +0200 Subject: Tagmail colorize in emacs reader not terminal output --- config/doom/config.org | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'config') diff --git a/config/doom/config.org b/config/doom/config.org index 3e1a422..cce1403 100644 --- a/config/doom/config.org +++ b/config/doom/config.org @@ -379,13 +379,20 @@ this new window. (completing-read "Which mailbox")) (kill-buffer buffer))))) + +(define-derived-mode mail-sync-log-mode comint-mode "mail-sync-log" + "Major mode for reading mail sync." + ;; code for syntax highlighting + (setq font-lock-defaults `(((,(rx bol "[" (1+ (or letter space)) "]") . font-lock-warning-face) + (,(rx bol " [mv]") . font-lock-constant-face) + (,(rx bol " [rm]") . font-lock-keyword-face))))) + (defun on/fetch-all-email () "Start tagmail fetch on a subprocess." (interactive) (with-current-buffer (get-buffer-create "*E-mail fetch*") (pop-to-buffer (current-buffer)) - (comint-mode) - (ansi-color-for-comint-mode-on) + (mail-sync-log-mode) (make-process :name "E-mail fetch" :buffer (current-buffer) -- cgit v1.2.3