>>> "CG" == Christoph Groth <christ...@grothesque.org> writes:
> Uwe Brauer wrote: >> BTW I am still wondering that such a functionality is not implemented, >> yet. > Could you please post the complete code once you are more or less done > with it? After some discussion on the emacs devel list, I came up with a new function which you have to bind (defun check-bcc-gnus-article-followup-with-original () "This function warns you if your email address is not in the To or Cc field, unless it's a newsgroup post or the email is from a mailing list (List-Id or List-Post fields). If any of these conditions apply, it directly calls `gnus-article-followup-with-original`." (interactive) (gnus-summary-select-article-buffer) (let ((to-field (message-fetch-field "To")) (cc-field (message-fetch-field "Cc")) (newsgroup-field (message-fetch-field "Newsgroups")) (list-id-field (message-fetch-field "List-Id")) (list-post-field (message-fetch-field "List-Post"))) (if (or (and to-field (string-match-p (regexp-quote user-mail-address) to-field)) (and cc-field (string-match-p (regexp-quote user-mail-address) cc-field)) list-id-field list-post-field newsgroup-field) ;; Case 1-4: If To, Cc, List-Id, List-Post, or Newsgroups field applies, directly follow up (gnus-article-followup-with-original) ;; Case 5: If none of the conditions are met, warn the user (with-output-to-temp-buffer "gnus-bcc-check-buffer" (princ "List of functions\n") (princ "1: gnus-article-followup-with-original\n") (princ "2: gnus-article-reply-with-original\n") (princ "3: abort\n")) (let ((ch (string-to-char (read-string "Warning: Followup? But you are not on the TO or CC field, and this is not a mailing list email. A reply may reveal that you were Bcc'ed. Which choice: 1: 2: 3: ")))) (call-interactively (cond ((eql ch ?1) #'gnus-article-followup-with-original) ((eql ch ?2) #'gnus-article-reply-with-original) ((eql ch ?3) #'quit-window) (t (error 'args-out-of-range '(1 2 3 ch)))))) (kill-buffer "gnus-bcc-check-buffer")))) Enjoy -- I strongly condemn Hamas heinous despicable pogroms/atrocities on Israel I strongly condemn Putin's war of aggression against Ukraine. I support to deliver weapons to Ukraine's military. I support the EU and NATO membership of Ukraine.
smime.p7s
Description: S/MIME cryptographic signature