diff --git a/NEWS.org b/NEWS.org index 2993a0db..0de191f4 100644 --- a/NEWS.org +++ b/NEWS.org @@ -21,7 +21,12 @@ one. - allow for transforming mailing-list names for display, using `mu4e-mailing-list-patterns'. - - some optimizations in indexing + - some optimizations in indexing (~30% faster in some cases) + - new variable mu4e-user-agent-string, to customize the User-Agent: + header. + - when removing the "In-reply-to" header from replies, mu4e will + also remove the (hidden) References header, effectively creating + a new message-thread. ** 0.9.13 diff --git a/mu4e/mu4e-compose.el b/mu4e/mu4e-compose.el index f46eead7..98e0483e 100644 --- a/mu4e/mu4e-compose.el +++ b/mu4e/mu4e-compose.el @@ -264,6 +264,14 @@ Ie. either 'name ' or 'email')." (add-hook 'completion-at-point-functions 'mu4e~compose-complete-contact nil t)) + +(defun mu4e~remove-refs-maybe () + "Remove the References: header if the In-Reply-To header is +missing. This allows the user to effectively start a new +message-thread by removing the In-Reply-To header." + (unless (message-fetch-field "in-reply-to") + (message-remove-header "References"))) + ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (defvar mu4e-compose-mode-map nil "Keymap for \"*mu4e-compose*\" buffers.") @@ -303,6 +311,8 @@ Ie. either 'name ' or 'email')." ;; setup the fcc-stuff, if needed (add-hook 'message-send-hook (lambda () ;; mu4e~compose-save-before-sending + ;; when in-reply-to was removed, remove references as well. + (mu4e~remove-refs-maybe) ;; for safety, always save the draft before sending (set-buffer-modified-p t) (save-buffer) @@ -621,6 +631,8 @@ end of the buffer." (define-key mu4e-compose-mode-map (vector 'remap 'end-of-buffer) 'mu4e-compose-goto-bottom) + + (provide 'mu4e-compose) ;; Load mu4e completely even when this file was loaded through diff --git a/mu4e/mu4e.texi b/mu4e/mu4e.texi index e54593bd..15f99d9d 100644 --- a/mu4e/mu4e.texi +++ b/mu4e/mu4e.texi @@ -533,8 +533,8 @@ updates - for example when receiving new mail. See writing mail and inherits the setup for sending mail as well. For sending mail using @abbr{SMTP}, @t{mu4e} uses @t{smtpmail} -(@inforef{Top,,smtpmail}). This package supports many different ways to send -mail; please refer to its documentation for the details. +(@inforef{Top,,smtpmail}). This package supports many different ways to +send mail; please refer to its documentation for the details. Here, we only provide some simple examples - for more, see @ref{Example configurations}. @@ -3444,9 +3444,13 @@ You can drag-and-drop from your desktop; alternatively, you can use @t{dired} @item @emph{@t{mu4e} seems to remove myself from the @t{Cc:}-list; how can I prevent that?} Set @code{mu4e-compose-keep-self-cc} to @t{t} in your configuration. +@item @emph{How can I start a new message-thread from a reply?} Remove the @t{In-Reply-To} header, +and @t{mu4e} automatically removes the (hidden) @t{References} header as +well when sending it. This makes the message show up as a top-level +message rather than as a response. @item @emph{How can I sign or encrypt messages?} You can do so using @command{emacs}' -MIME-support -- check the @t{Attachments}-menu while composing a message. Also -see @ref{Signing and encrypting}. +MIME-support -- check the @t{Attachments}-menu while composing a +message. Also see @ref{Signing and encrypting}. @item @emph{Can I use @t{BBDB} with @t{mu4e}?} Yes, with the current (2015-06-23) development release of BBDB @url{http://savannah.nongnu.org/projects/bbdb/}, or releases of BBDB