[mu4e] Update mu4e only when appropriate

Trigger mail update only when the server is the one currently
active (the one associated to the running activity)
master
Jacopo De Simoi 3 years ago
parent 47d4d1fec3
commit c72d070f23
  1. 7
      global.org

@ -764,6 +764,13 @@
;; define 'z' as the shortcut
(add-to-list 'mu4e-view-actions
'("zCreate agenda item for meeting" . create-item-for-meeting) t)
(advice-add 'mu4e-update-mail-and-index :around
(lambda (orig-fun &rest args)
"Only trigger an update if the server is the one that should
currently be active; otherwise each mu4e instance will trigger an
update"
(when (string-equal server-name (kde-current-activity-name))
(apply orig-fun args))))
(advice-add 'mu4e~header-line-format :around
(lambda (orig-fun &rest args)

Loading…
Cancel
Save