[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/org-mime 168fe3a6a1 092/118: Merge pull request #51 from b
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/org-mime 168fe3a6a1 092/118: Merge pull request #51 from borwickatuw/master |
Date: |
Wed, 5 Jan 2022 07:58:49 -0500 (EST) |
branch: elpa/org-mime
commit 168fe3a6a15695c9f987ddda8eb1bdf41c849bb3
Merge: 744f5f3315 2581fc2dd9
Author: Chen Bin <chenbin.sh@gmail.com>
Commit: GitHub <noreply@github.com>
Merge pull request #51 from borwickatuw/master
org-mime-confirm-when-no-multipart function + docs
---
README.org | 8 ++++++++
org-mime.el | 12 ++++++++++++
2 files changed, 20 insertions(+)
diff --git a/README.org b/README.org
index f53ebdec95..66890a1f89 100644
--- a/README.org
+++ b/README.org
@@ -149,6 +149,14 @@ ASCII export options:
(setq org-mime-export-ascii 'utf-8)
#+end_src
+** Prompt for confirmation if message has no HTML
+
+If you plan to run =org-mime-htmlize= on all your email, you may want a
confirmation if it appears you're sending an email without multipart content.
To do this, add a hook to =message-send-hook= to your init file:
+
+#+begin_src elisp
+(add-hook 'message-send-hook 'org-mime-confirm-when-no-multipart)
+#+end_src
+
* Support legacy Emacs versions
- 0.1.6 is the last version to support Emacs 24
* Development
diff --git a/org-mime.el b/org-mime.el
index 28274c5f10..f2f29761dc 100644
--- a/org-mime.el
+++ b/org-mime.el
@@ -788,6 +788,18 @@ Following headline properties can determine the mail
headers,
(t
(message "Can not find plain text mail.")))))
+(defun org-mime-confirm-when-no-multipart ()
+ "Prompts whether to send email if the buffer does not seem to be html-ized"
+ (let ((found-multipart (save-excursion
+ (save-restriction
+ (widen)
+ (goto-char (point-min))
+ (search-forward "<#multipart type=alternative>"
nil t)))))
+ (when (and (not found-multipart)
+ (not (y-or-n-p "org-mime-htmlize not called; send anyway?")))
+ (setq quit-flag t))))
+
+
(provide 'org-mime)
;; Local Variables:
;; coding: utf-8
- [nongnu] elpa/org-mime 0752659f7a 042/118: No drawer exporting (default since Emacs 25), (continued)
- [nongnu] elpa/org-mime 0752659f7a 042/118: No drawer exporting (default since Emacs 25), ELPA Syncer, 2022/01/05
- [nongnu] elpa/org-mime db707a7337 040/118: Merge pull request #15 from unhammer/patch-1, ELPA Syncer, 2022/01/05
- [nongnu] elpa/org-mime bc61d4de7d 045/118: Merge pull request #18 from jkitchin/master, ELPA Syncer, 2022/01/05
- [nongnu] elpa/org-mime 7e89b4b741 053/118: move cond out of the cleanup function, ELPA Syncer, 2022/01/05
- [nongnu] elpa/org-mime 7bcb075550 060/118: CI and TDD, fixed some minor bug. bump 0.1.2, ELPA Syncer, 2022/01/05
- [nongnu] elpa/org-mime 286330fa15 069/118: fixed: LaTeX fragment not exported correctly, ELPA Syncer, 2022/01/05
- [nongnu] elpa/org-mime 6c7ddeaade 068/118: fixed CI, ELPA Syncer, 2022/01/05
- [nongnu] elpa/org-mime 73c13fdd0b 075/118: Merge pull request #39 from czan/master, ELPA Syncer, 2022/01/05
- [nongnu] elpa/org-mime 1162095645 086/118: Catch signature in html convert, ELPA Syncer, 2022/01/05
- [nongnu] elpa/org-mime 722a295672 088/118: Merge pull request #48 from ahttraga/sigfix, ELPA Syncer, 2022/01/05
- [nongnu] elpa/org-mime 168fe3a6a1 092/118: Merge pull request #51 from borwickatuw/master,
ELPA Syncer <=
- [nongnu] elpa/org-mime 4e5d50789b 097/118: Clean up name of test file in comment, ELPA Syncer, 2022/01/05
- [nongnu] elpa/org-mime 73fdd3f40d 098/118: Merge pull request #53 from tomheon/clean-up-test-header, ELPA Syncer, 2022/01/05
- [nongnu] elpa/org-mime d71f57dc0d 096/118: Add a simple test for quoting of multi-line paragraphs, ELPA Syncer, 2022/01/05
- [nongnu] elpa/org-mime 5df12989cd 101/118: clean code, ELPA Syncer, 2022/01/05
- [nongnu] elpa/org-mime d725955399 105/118: stop bundling htmlize, ELPA Syncer, 2022/01/05
- [nongnu] elpa/org-mime e5345ae5b6 104/118: fixed ci, ELPA Syncer, 2022/01/05
- [nongnu] elpa/org-mime 23cc52bb53 111/118: donot htmlize security signature and attachment, ELPA Syncer, 2022/01/05
- [nongnu] elpa/org-mime d52a7b52b6 114/118: fixed revert plain text email bug, ELPA Syncer, 2022/01/05
- [nongnu] elpa/org-mime b1fc1cc53c 116/118: Fix byte-compiler warnings, ELPA Syncer, 2022/01/05
- [nongnu] elpa/org-mime 613969effc 118/118: Merge pull request #67 from skangas/silence-byte-compiler, ELPA Syncer, 2022/01/05