aboutsummaryrefslogtreecommitdiff
path: root/.emacs.local.d/modes/mu4e.el
diff options
context:
space:
mode:
authorRaúl Benencia <rul@kalgan.cc>2019-06-23 11:43:30 -0700
committerRaúl Benencia <rul@kalgan.cc>2019-06-23 13:32:01 -0700
commit284c8327c95bb0c71b111ebf95723a35a478295c (patch)
treefaea9db4b1bba00d73d33b2065ed102f88b76b2c /.emacs.local.d/modes/mu4e.el
Add emacs config
Diffstat (limited to '.emacs.local.d/modes/mu4e.el')
-rw-r--r--.emacs.local.d/modes/mu4e.el61
1 files changed, 61 insertions, 0 deletions
diff --git a/.emacs.local.d/modes/mu4e.el b/.emacs.local.d/modes/mu4e.el
new file mode 100644
index 0000000..da8b7c8
--- /dev/null
+++ b/.emacs.local.d/modes/mu4e.el
@@ -0,0 +1,61 @@
+(require 'mu4e)
+
+;; sending mail
+(setq message-send-mail-function 'message-send-mail-with-sendmail
+ sendmail-program "/home/lur/bin/te-msmtp"
+ user-mail-address "raul@thousandeyes.com"
+ user-full-name "Raúl Benencia")
+
+(setq mu4e-user-mail-address-list (list "raul@thousandeyes.com"))
+
+(setq message-kill-buffer-on-exit t)
+;; Use fancy chars
+(setq mu4e-use-fancy-chars t)
+;; don't save message to Sent Messages, Gmail/IMAP takes care of this
+(setq mu4e-sent-messages-behavior 'delete)
+(setq mu4e-update-interval 60) ;; update every 5 minutes
+
+;; use 'fancy' non-ascii characters in various places in mu4e
+;;(setq mu4e-use-fancy-chars t)
+
+(setq relevant-maildirs " (maildir:/INBOX OR maildir:/jira OR maildir:/news OR maildir:/git)")
+(mu4e-alert-enable-notifications)
+(mu4e-alert-set-default-style 'libnotify)
+(setq mu4e-alert-interesting-mail-query
+ (concat "flag:unread"
+ " AND NOT flag:trashed"
+ " AND" relevant-maildirs))
+
+(mu4e-alert-set-default-style 'libnotify)
+;;(add-hook 'after-init-hook #'mu4e-alert-enable-notifications)
+(add-hook 'after-init-hook #'mu4e-alert-enable-mode-line-display)
+
+(setq mu4e-bookmarks
+ `(,(make-mu4e-bookmark
+ :name "INBOX"
+ :query "maildir:/INBOX"
+ :key ?i)
+ ,(make-mu4e-bookmark
+ :name "Unread messages"
+ :query (concat "flag:unread AND NOT flag:trashed AND" relevant-maildirs)
+ :key ?u)
+ ,(make-mu4e-bookmark
+ :name "Today's messages"
+ :query (concat "date:today..now AND" relevant-maildirs)
+ :key ?t)
+ ,(make-mu4e-bookmark
+ :name "Last 7 days"
+ :query (concat "date:7d..now AND" relevant-maildirs)
+ :key ?w)
+ ,(make-mu4e-bookmark
+ :name "Today's unread logs "
+ :query (concat "date:today..now flag:unread AND NOT" relevant-maildirs)
+ :key ?l)
+ ,(make-mu4e-bookmark
+ :name "Today's logs "
+ :query (concat "date:today..now AND NOT maildir:/fim AND NOT" relevant-maildirs)
+ :key ?l))
+)
+
+;; (require 'mu4e-maildirs-extension)
+;; (mu4e-maildirs-extension)
nihil fit ex nihilo