diff options
author | Luke Shumaker <LukeShu@sbcglobal.net> | 2013-01-04 10:44:44 -0500 |
---|---|---|
committer | Luke Shumaker <LukeShu@sbcglobal.net> | 2013-01-27 17:27:45 -0500 |
commit | 97b9c96fccd8496d1f7c5b433f1784640b327664 (patch) | |
tree | 81d61583cf06fd6f47e15241060635895d0b5144 | |
parent | cf15a5a3c8607dc0ddd61acfe8885883d83b4cb2 (diff) |
use mailcrypt with wanderlust
-rw-r--r-- | .config/emacs/init.el | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/.config/emacs/init.el b/.config/emacs/init.el index 65634cb..c026dd7 100644 --- a/.config/emacs/init.el +++ b/.config/emacs/init.el @@ -58,6 +58,34 @@ ;; General settings ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +(require 'mailcrypt) +(mc-setversion "gpg") +(add-hook 'wl-summary-mode-hook 'mc-install-read-mode) +(add-hook 'wl-mail-setup-hook 'mc-install-write-mode) + +(defun mc-wl-verify-signature () + (interactive) + (save-window-excursion + (wl-summary-jump-to-current-message) + (mc-verify))) + +(defun mc-wl-decrypt-message () + (interactive) + (save-window-excursion + (wl-summary-jump-to-current-message) + (let ((inhibit-read-only t)) + (mc-decrypt)))) + +(eval-after-load "mailcrypt" + '(setq mc-modes-alist + (append + (quote + ((wl-draft-mode (encrypt . mc-encrypt-message) + (sign . mc-sign-message)) + (wl-summary-mode (decrypt . mc-wl-decrypt-message) + (verify . mc-wl-verify-signature)))) + mc-modes-alist))) + ;(load "mdmua") (load "emacsutils") |