Browse Source

Move email to desktop module

main
parent
commit
c77e0d1656
  1. 41
      modules/desktop.el
  2. 38
      modules/writing.el

41
modules/desktop.el

@ -1,4 +1,43 @@
(setenv "BROWSER" dotfiles/browser)
(use-package mu4e
:load-path "/usr/share/emacs/site-lisp/mu4e"
:custom (mu4e-maildir "~/.cache/mail")
(mu4e-update-interval (* 5 60))
(mu4e-get-mail-command "mbsync -a")
(mu4e-compose-format-flowed t)
(mu4e-change-filenames-when-moving t)
(message-send-mail-function 'smtpmail-send-it)
(mml-secure-openpgp-signers '("37AB1CB72B741E478CA026D43025DCBD46F81C0F"))
(mu4e-compose-signature (concat "Chris Hayward\n"
"https://chrishayward.xyz\n"))
:config
(add-hook 'message-send-hook 'mml-secure-message-sign-pgpmime)
(setq mu4e-contexts
(list
;; Main
;; chris@chrishayward.xyz
(make-mu4e-context
:name "Main"
:match-func
(lambda (msg)
(when msg
(string-prefix-p "/Main" (mu4e-message-field msg :maildir))))
:vars
'((user-full-name . "Christopher James Hayward")
(user-mail-address . "chris@chrishayward.xyz")
(smtpmail-smtp-server . "mail.chrishayward.xyz")
(smtpmail-smtp-service . 587)
(smtpmail-stream-type . starttls))))))
(use-package mu4e-alert
:custom (mu4e-alert-set-default-style 'libnotify)
:config (mu4e-alert-enable-notifications)
(mu4e-alert-enable-mode-line-display))
(dotfiles/leader
"m" '(mu4e :which-key "Mail"))
(dotfiles/leader
"b" '(dotfiles/run-in-background dotfiles/browser :which-key "Browser"))
(defun dotfiles/run (command) (defun dotfiles/run (command)
"Run an external process." "Run an external process."

38
modules/writing.el

@ -84,44 +84,6 @@
#+AUTHOR: Christopher James Hayward #+AUTHOR: Christopher James Hayward
"))) ")))
(use-package mu4e
:load-path "/usr/share/emacs/site-lisp/mu4e"
:custom (mu4e-maildir "~/.cache/mail")
(mu4e-update-interval (* 5 60))
(mu4e-get-mail-command "mbsync -a")
(mu4e-compose-format-flowed t)
(mu4e-change-filenames-when-moving t)
(message-send-mail-function 'smtpmail-send-it)
(mml-secure-openpgp-signers '("37AB1CB72B741E478CA026D43025DCBD46F81C0F"))
(mu4e-compose-signature (concat "Chris Hayward\n"
"https://chrishayward.xyz\n"))
:config
(add-hook 'message-send-hook 'mml-secure-message-sign-pgpmime)
(setq mu4e-contexts
(list
;; Main
;; chris@chrishayward.xyz
(make-mu4e-context
:name "Main"
:match-func
(lambda (msg)
(when msg
(string-prefix-p "/Main" (mu4e-message-field msg :maildir))))
:vars
'((user-full-name . "Christopher James Hayward")
(user-mail-address . "chris@chrishayward.xyz")
(smtpmail-smtp-server . "mail.chrishayward.xyz")
(smtpmail-smtp-service . 587)
(smtpmail-stream-type . starttls))))))
(use-package mu4e-alert
:custom (mu4e-alert-set-default-style 'libnotify)
:config (mu4e-alert-enable-notifications)
(mu4e-alert-enable-mode-line-display))
(dotfiles/leader
"m" '(mu4e :which-key "Mail"))
(unless (string-match-p "\\.gpg" org-agenda-file-regexp) (unless (string-match-p "\\.gpg" org-agenda-file-regexp)
(setq org-agenda-file-regexp (setq org-agenda-file-regexp
(replace-regexp-in-string "\\\\\\.org" "\\\\.org\\\\(\\\\.gpg\\\\)?" (replace-regexp-in-string "\\\\\\.org" "\\\\.org\\\\(\\\\.gpg\\\\)?"

Loading…
Cancel
Save