Add and configure mu4e to read/send emails from emacs.

The mu4e package was installed through debian apt, I
have to find a way to manage it with straight.el
This commit is contained in:
Mateus Pinto Rodrigues
2019-10-25 16:46:19 -03:00
parent 671240b19f
commit f16b339144
4 changed files with 44 additions and 0 deletions

View File

@@ -43,6 +43,9 @@
;; git ;; git
(use-package magit) (use-package magit)
;; This package was installed with debian, I hope this works
(use-package mu4e)
;;R ;;R
(use-package auto-complete) (use-package auto-complete)
(use-package ess (use-package ess

36
elisp/mu4e-setup.el Normal file
View File

@@ -0,0 +1,36 @@
;; Largely based on ... and ...
;; use mu4e for e-mail in emacs
(setq mail-user-agent 'mu4e-user-agent)
;; Set the root maildir
(setq mu4e-maildir "~/.mail")
;; some other dirs
(setq mu4e-sent-folder "/posteo/Sent"
mu4e-drafts-folder "/drafts")
;; a list of user's e-mail addresses
(setq mu4e-user-mail-address-list '("mprodrigues@posteo.net"))
;; the headers to show in the headers list -- a pair of a field
;; and its width, with `nil' meaning 'unlimited'
;; (better only use that for the last field.
;; These are the defaults:
(setq mu4e-headers-fields
'( (:date . 25) ;; alternatively, use :human-date
(:flags . 6)
(:from . 22)
(:subject . nil))) ;; alternatively, use :thread-subject
;; general emacs mail settings; used when composing e-mail
;; the non-mu4e-* stuff is inherited from emacs/message-mode
(setq mu4e-compose-reply-to-address "mprodrigues@posteo.net"
user-mail-address "mprodrigues@posteo.net"
user-full-name "Mateus P. Rodrigues")
;; SMTP configuration
(setq message-send-mail-function 'smtpmail-send-it
user-mail-address "mprodrigues@posteo.net"
smtpmail-default-smtp-server "posteo.de"
smtpmail-smtp-server "posteo.de"
smtpmail-smtp-service 587)

View File

@@ -7,6 +7,9 @@
;; Set default encoding ;; Set default encoding
(setq current-language-environment "UTF-8") (setq current-language-environment "UTF-8")
;; Handle pinentry in minibuffer if called from emacs
(setq epg-pinentry-mode "loopback")
;; Always do syntax highlighting ;; Always do syntax highlighting
(global-font-lock-mode 1) (global-font-lock-mode 1)

View File

@@ -23,6 +23,8 @@
'("gnu" . "http://elpa.gnu.org/packages/")) '("gnu" . "http://elpa.gnu.org/packages/"))
(add-to-list 'load-path "~/.emacs.d/elisp/") (add-to-list 'load-path "~/.emacs.d/elisp/")
;; load debian mu4e package
(add-to-list 'load-path "/usr/share/emacs/site-lisp/mu4e")
(load "~/.emacs.d/elisp/settings.el") (load "~/.emacs.d/elisp/settings.el")
(load "~/.emacs.d/elisp/extras.el") (load "~/.emacs.d/elisp/extras.el")