Tassilo Horn
unread,Nov 12, 2024, 12:36:33 AM11/12/24Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Joost Kremers, Nikos Patikas, Tamas Papp, mu-di...@googlegroups.com
Joost Kremers <
joostk...@fastmail.fm> writes:
>> (define-key mu4e-compose-minor-mode-map "R" 'mu4e-reply-menu-hydra/body)
>>
>> (defhydra mu4e-reply-menu-hydra (:color pink :hint nil)
>> "Reply Menu:"
>> ("c" nil "cancel")
>> ("a" #'mu4e-compose-wide-reply "Reply to all" :color blue)
>> ("s" #'mu4e-compose-reply "Reply to sender" :color blue)
>> )
>
> Yes, I did something similar, though without hydra:
>
> ```
>
> (defun jk/compose-mode-maybe-wide-reply ()
> "Reply to a message, asking whether it should be a wide reply or not."
> (interactive)
> (mu4e-compose-reply (y-or-n-p "Reply to all? ")))
> ```
>
> Then bind that function to R in `mu4e-compose-minor-mode-map`:
My version is this:
--8<---------------cut here---------------start------------->8---
;; I keep on sending replies (R) instead of wide replies (W), so better make
;; R ask if I'm really sure.
(defun th/mu4e-compose-reply-filter-args (args)
"Ask if we actually want a wide reply (Reply All)."
(list (or (car args) ;; the first arg is `wide'.
(yes-or-no-p "Wide reply? "))))
(advice-add #'mu4e-compose-reply
:filter-args
#'th/mu4e-compose-reply-filter-args)
--8<---------------cut here---------------end--------------->8---
So when I hit R, it'll query if I actually want a wide reply each time.
Bye,
Tassilo