This repository has been archived on 2024-10-22. You can view files and clone it, but cannot push or open issues or pull requests.
spacemacs/layers/+email/mu4e/packages.el

42 lines
1.3 KiB
EmacsLisp
Raw Normal View History

;;; packages.el --- mu4e Layer packages File for Spacemacs
2015-08-02 05:30:30 +00:00
;;
;; Copyright (c) 2012-2014 Sylvain Benner
;; Copyright (c) 2014-2015 Sylvain Benner & Contributors
;;
;; Author: Sylvain Benner <sylvain.benner@gmail.com>
;; URL: https://github.com/syl20bnr/spacemacs
;;
;; This file is not part of GNU Emacs.
;;
;;; License: GPLv3
(setq mu4e-packages
'((mu4e :location built-in)))
2015-08-02 05:30:30 +00:00
(defun mu4e/init-mu4e ()
(use-package mu4e
:commands (mu4e mu4e-compose-new)
2015-08-02 05:30:30 +00:00
:init
(progn
(spacemacs/set-leader-keys "a M" 'mu4e)
2015-08-02 05:30:30 +00:00
(global-set-key (kbd "C-x m") 'mu4e-compose-new))
:config
(progn
(evilified-state-evilify-map mu4e-main-mode-map
2015-08-02 05:30:30 +00:00
:mode mu4e-main-mode
:bindings
(kbd "j") 'mu4e~headers-jump-to-maildir)
(evilified-state-evilify-map mu4e-headers-mode-map
:mode mu4e-headers-mode)
(evilified-state-evilify-map mu4e-view-mode-map
:mode mu4e-view-mode)
2015-08-02 05:30:30 +00:00
(setq mu4e-completing-read-function 'helm--completing-read-default)
(add-to-list 'mu4e-view-actions
'("View in browser" . mu4e-action-view-in-browser) t)
(when mu4e-account-alist
(add-hook 'mu4e-compose-pre-hook 'mu4e/set-account)
(add-hook 'message-sent-hook 'mu4e/mail-account-reset)))))