aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiquel Sabaté Solà <msabate@suse.com>2019-05-13 17:27:58 +0200
committerMiquel Sabaté Solà <msabate@suse.com>2019-05-13 17:27:58 +0200
commit535e13930d81db17e5afe06b85142c5d97bc5df9 (patch)
tree2b2e45d54dcf8a67414ab16c34437f8171a5acb5
parent68501ade548eaadfc466f01429aefc8833fa79e2 (diff)
downloaddotfiles-535e13930d81db17e5afe06b85142c5d97bc5df9.tar.gz
dotfiles-535e13930d81db17e5afe06b85142c5d97bc5df9.zip
emacs: added the "gnus mode toggle" action
Attached .eml files are hard to visualize if mu4e-view-use-gnus is not set to true. I've defined a header action because I know I will forget about the name of this variable. Signed-off-by: Miquel Sabaté Solà <msabate@suse.com>
-rw-r--r--emacs/init.org14
1 files changed, 14 insertions, 0 deletions
diff --git a/emacs/init.org b/emacs/init.org
index ef37576..3af3ab1 100644
--- a/emacs/init.org
+++ b/emacs/init.org
@@ -1209,6 +1209,20 @@ These are the defaults:
(:subject . nil)))
#+END_SRC
+Add as a header action to toggle gnus mode for the view mode. I'm doing this
+because this is way better to visualize attached .eml emails.
+
+#+BEGIN_SRC elisp
+(defun mssola-toggle-gnus-mode (msg)
+ "Toggle gnus on view mode from now on."
+ (if mu4e-view-use-gnus
+ (setq mu4e-view-use-gnus nil)
+ (setq mu4e-view-use-gnus t)))
+
+(add-to-list 'mu4e-headers-actions
+ '("gnus mode toggle" . mssola-toggle-gnus-mode) t)
+#+END_SRC
+
Show images
#+BEGIN_SRC elisp