From 181f17a6f4627b62c98c70e63439ab5feb61c3c4 Mon Sep 17 00:00:00 2001 From: TEC Date: Tue, 3 Aug 2021 02:36:09 +0800 Subject: [PATCH 1/3] fix(mu4e): account for signature change in v1.6 Mu4e 1.6 changes the signature of `mu4e-draft-open'. Since we don't care about the args replace funcall with apply to make sure it's happy no matter how many args it expected. --- modules/email/mu4e/config.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/email/mu4e/config.el b/modules/email/mu4e/config.el index 81b0dcbb6..9893f3f80 100644 --- a/modules/email/mu4e/config.el +++ b/modules/email/mu4e/config.el @@ -282,11 +282,11 @@ Usefull for affecting HTML export config.") (+mu4e-compose-org-msg-handle-toggle (/= 1 (or toggle-p 0))) (funcall orig-fn)) - (defadvice! +mu4e-draft-open-signature-a (orig-fn compose-type &optional msg) + (defadvice! +mu4e-draft-open-signature-a (orig-fn &rest args) "Prevent `mu4e-compose-signature' from being used with `org-msg-mode'." :around #'mu4e-draft-open (let ((mu4e-compose-signature (unless org-msg-mode mu4e-compose-signature))) - (funcall orig-fn compose-type msg))) + (apply orig-fn args))) (map! :map org-msg-edit-mode-map "TAB" #'org-msg-tab) ; only bound by default From 61126c6bb48c96bb8f5865f3293b5b08fa121d2e Mon Sep 17 00:00:00 2001 From: TEC Date: Tue, 3 Aug 2021 02:37:25 +0800 Subject: [PATCH 2/3] fix(mu4e): improve mu-lock compatability with mac On mac process args aren't defined, but comm is. Since comm also works on Linux, we now check for that instead, accounting for a potential capitalisation difference. --- modules/email/mu4e/autoload/mu-lock.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/email/mu4e/autoload/mu-lock.el b/modules/email/mu4e/autoload/mu-lock.el index 7a0e6375b..2387f721f 100644 --- a/modules/email/mu4e/autoload/mu-lock.el +++ b/modules/email/mu4e/autoload/mu-lock.el @@ -22,7 +22,7 @@ (insert-file-contents +mu4e-lock-file) (buffer-string)))) (process (process-attributes pid))) - (if (and process (string-match-p "emacs" (alist-get 'args process))) + (if (and process (string-match-p "[Ee]macs" (alist-get 'comm process))) (cons pid process) (delete-file +mu4e-lock-file) nil)))) From eaa392c00b928d3125e5f8e228147318677366ff Mon Sep 17 00:00:00 2001 From: TEC Date: Tue, 3 Aug 2021 02:40:15 +0800 Subject: [PATCH 3/3] docs(mu4e): fix a typo (errors, plural) Someone politely requested I add this to my PR on Discord ... why not. --- modules/email/mu4e/README.org | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/email/mu4e/README.org b/modules/email/mu4e/README.org index 78df081a8..b5b1fa89f 100644 --- a/modules/email/mu4e/README.org +++ b/modules/email/mu4e/README.org @@ -260,7 +260,7 @@ If you have completely lost your install then you can use this handy command! #+BEGIN_SRC shell find / -type d -iname '*mu4e*' -# I reccomend rerouting all of the error to /dev/null +# I recommend rerouting all of the errors to /dev/null find / -type d -iname '*mu4e*' 2> /dev/null #+END_SRC