mirror of
https://github.com/SqrtMinusOne/dotfiles.git
synced 2025-12-11 19:45:25 +03:00
feat(mail): warn if no subject
This commit is contained in:
parent
aabea47b45
commit
636a7eae1c
2 changed files with 15 additions and 0 deletions
|
|
@ -119,3 +119,10 @@
|
||||||
|
|
||||||
(with-eval-after-load 'notmuch-mua
|
(with-eval-after-load 'notmuch-mua
|
||||||
(advice-add #'notmuch-mua-reply :after #'my/message-maybe-fix-signature))
|
(advice-add #'notmuch-mua-reply :after #'my/message-maybe-fix-signature))
|
||||||
|
|
||||||
|
(defun my/message-ensure-subject ()
|
||||||
|
(unless (or (message-field-value "Subject")
|
||||||
|
(y-or-n-p "No subject. Send? "))
|
||||||
|
(user-error "Aborting.")))
|
||||||
|
|
||||||
|
(add-hook 'notmuch-mua-send-hook #'my/message-ensure-subject)
|
||||||
|
|
|
||||||
8
Mail.org
8
Mail.org
|
|
@ -589,7 +589,15 @@ Then advice the =notmuch-mua-reply= function:
|
||||||
(with-eval-after-load 'notmuch-mua
|
(with-eval-after-load 'notmuch-mua
|
||||||
(advice-add #'notmuch-mua-reply :after #'my/message-maybe-fix-signature))
|
(advice-add #'notmuch-mua-reply :after #'my/message-maybe-fix-signature))
|
||||||
#+end_src
|
#+end_src
|
||||||
|
** Warn if no subject
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(defun my/message-ensure-subject ()
|
||||||
|
(unless (or (message-field-value "Subject")
|
||||||
|
(y-or-n-p "No subject. Send? "))
|
||||||
|
(user-error "Aborting.")))
|
||||||
|
|
||||||
|
(add-hook 'notmuch-mua-send-hook #'my/message-ensure-subject)
|
||||||
|
#+end_src
|
||||||
* mailcap
|
* mailcap
|
||||||
mailcap file is a file which defines how to read to different MIME types. Notmuch also uses it, so why not keep it here.
|
mailcap file is a file which defines how to read to different MIME types. Notmuch also uses it, so why not keep it here.
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue