diff --git a/.emacs.d/init.el b/.emacs.d/init.el index df78dd0..4786b94 100644 --- a/.emacs.d/init.el +++ b/.emacs.d/init.el @@ -305,33 +305,9 @@ value `italic'." (dashboard-setup-startup-hook) ;; mu4e -(let - ((mu4e-path - (concat (getenv "HOME") "/.nix-profile/share/emacs/site-lisp/mu4e/"))) - (unless (file-exists-p mu4e-path) - (throw 'mu4e-load-path "cannot locate mu4e load path")) - (add-to-list 'load-path mu4e-path)) -(require 'mu4e) -(setq mu4e-maildir "~/mail" - mu4e-get-mail-command "mbsync -a" - mu4e-update-interval (* 5 60) ; 5 minutes - mu4e-change-filenames-when-moving t ; prevent mail syncing issues with mbsync - mu4e-refile-folder "/Archive" - mu4e-drafts-folder "/Drafts" - mu4e-sent-folder "/Sent" - mu4e-trash-folder "/Trash" - mu4e-maildir-shortcuts '(("/Inbox" . ?i) - ("/Archive" . ?a) - ("/Drafts" . ?d))) -(global-set-key (kbd "C-c m") 'mu4e) - -;; smtp -(setq message-send-mail-function 'smtpmail-send-it - user-mail-address "jeremy@baxters.nz" - user-full-name "Jeremy Baxter" - smtpmail-smtp-server "smtp.migadu.com" - smtpmail-smtp-service 465 - smtpmail-stream-type 'ssl) +(let ((mu4e-file "~/.emacs.d/mu4e.el")) + (when (file-exists-p mu4e-file) + (load mu4e-file))) ;; other packages (require 'esv) diff --git a/.emacs.d/mu4e.el b/.emacs.d/mu4e.el new file mode 100644 index 0000000..3f70ebe --- /dev/null +++ b/.emacs.d/mu4e.el @@ -0,0 +1,29 @@ +(let + ((mu4e-path + (concat (getenv "HOME") "/.nix-profile/share/emacs/site-lisp/mu4e/"))) + (unless (file-exists-p mu4e-path) + (throw 'mu4e-load-path "cannot locate mu4e load path")) + (add-to-list 'load-path mu4e-path)) +(require 'mu4e) +(setq mu4e-maildir "~/mail" + mu4e-get-mail-command "mbsync -a" + mu4e-update-interval (* 5 60) ; 5 minutes + mu4e-change-filenames-when-moving t ; prevent mail syncing issues with mbsync + mu4e-refile-folder "/Archive" + mu4e-drafts-folder "/Drafts" + mu4e-sent-folder "/Sent" + mu4e-trash-folder "/Trash" + mu4e-maildir-shortcuts '(("/Inbox" . ?i) + ("/Archive" . ?a) + ("/Drafts" . ?d))) +(global-set-key (kbd "C-c m") 'mu4e) + +;; smtp +(setq message-send-mail-function 'smtpmail-send-it + user-mail-address "jeremy@baxters.nz" + user-full-name "Jeremy Baxter" + smtpmail-smtp-server "smtp.migadu.com" + smtpmail-smtp-service 465 + smtpmail-stream-type 'ssl) + +;;; mu4e.el ends here diff --git a/sync.sh b/sync.sh index a918d5d..7af4aae 100755 --- a/sync.sh +++ b/sync.sh @@ -12,6 +12,7 @@ cp "$HOME"/.profile . mkdir -p .emacs.d/ cp "$HOME"/.emacs.d/init.el .emacs.d/init.el +cp "$HOME"/.emacs.d/mu4e.el .emacs.d/mu4e.el mkdir -p .config/foot/ cp "$HOME"/.config/foot/foot.ini .config/foot/foot.ini mkdir -p .config/fuzzel/