* mu4e: improve docs for capturing / attaching message (and set them to message/rfc822)
This commit is contained in:
@ -85,8 +85,9 @@ forwarded or edited) in `mu4e-compose-pre-hook.")
|
|||||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
|
|
||||||
|
|
||||||
(defun mu4e-compose-attach-captured-message()
|
(defun mu4e-compose-attach-captured-message ()
|
||||||
"Insert the last captured message file as an attachment."
|
"Insert the last captured message (through
|
||||||
|
`mu4e-action-capture-message') file as an attachment."
|
||||||
(interactive)
|
(interactive)
|
||||||
(unless mu4e-captured-message
|
(unless mu4e-captured-message
|
||||||
(mu4e-warn "No message has been captured"))
|
(mu4e-warn "No message has been captured"))
|
||||||
@ -95,7 +96,7 @@ forwarded or edited) in `mu4e-compose-pre-hook.")
|
|||||||
(mu4e-warn "Captured message file not found"))
|
(mu4e-warn "Captured message file not found"))
|
||||||
(mml-attach-file
|
(mml-attach-file
|
||||||
path
|
path
|
||||||
"application/octet-stream"
|
"message/rfc822"
|
||||||
(or (plist-get mu4e-captured-message :subject) "No subject")
|
(or (plist-get mu4e-captured-message :subject) "No subject")
|
||||||
"attachment")))
|
"attachment")))
|
||||||
|
|
||||||
@ -490,7 +491,7 @@ needed, set the Fcc header, and register the handler function."
|
|||||||
;; value for this (such as "") breaks address completion and other things
|
;; value for this (such as "") breaks address completion and other things
|
||||||
(set (make-local-variable 'mail-header-separator)
|
(set (make-local-variable 'mail-header-separator)
|
||||||
(purecopy "--text follows this line--"))
|
(purecopy "--text follows this line--"))
|
||||||
|
|
||||||
(make-local-variable 'message-default-charset)
|
(make-local-variable 'message-default-charset)
|
||||||
;; if the default charset is not set, use UTF-8
|
;; if the default charset is not set, use UTF-8
|
||||||
(unless message-default-charset
|
(unless message-default-charset
|
||||||
@ -566,8 +567,7 @@ a file which our backend has conveniently saved for us (as a
|
|||||||
tempfile).
|
tempfile).
|
||||||
|
|
||||||
The name of the draft folder is constructed from the concatenation
|
The name of the draft folder is constructed from the concatenation
|
||||||
of `mu4e-maildir' and `mu4e-drafts-folder' (therefore, these must be
|
of `mu4e-maildir' and `mu4e-drafts-folder' (these must be set).
|
||||||
set).
|
|
||||||
|
|
||||||
The message file name is a unique name determined by
|
The message file name is a unique name determined by
|
||||||
`mu4e-send-draft-file-name'.
|
`mu4e-send-draft-file-name'.
|
||||||
@ -692,13 +692,13 @@ for draft messages."
|
|||||||
|
|
||||||
(unless (member compose-type '(reply forward edit new))
|
(unless (member compose-type '(reply forward edit new))
|
||||||
(mu4e-error "Invalid compose type '%S'" compose-type))
|
(mu4e-error "Invalid compose type '%S'" compose-type))
|
||||||
(when (and (eq compose-type 'edit)
|
(when (and (eq compose-type 'edit)
|
||||||
(not (member 'draft (mu4e-field-at-point :flags))))
|
(not (member 'draft (mu4e-field-at-point :flags))))
|
||||||
(mu4e-warn "Editing is only allowed for draft messages"))
|
(mu4e-warn "Editing is only allowed for draft messages"))
|
||||||
|
|
||||||
;; run the hooks
|
;; run the hooks
|
||||||
(mu4e~compose-run-hooks compose-type)
|
(mu4e~compose-run-hooks compose-type)
|
||||||
|
|
||||||
;; 'new is special, since it takes no existing message as arg therefore,
|
;; 'new is special, since it takes no existing message as arg therefore,
|
||||||
;; we don't need to call thec backend, and call the handler *directly*
|
;; we don't need to call thec backend, and call the handler *directly*
|
||||||
(if (eq compose-type 'new)
|
(if (eq compose-type 'new)
|
||||||
|
|||||||
@ -677,9 +677,10 @@ maildir:/bar(saTF)}.
|
|||||||
on the message at point. You can specify these actions using the variable
|
on the message at point. You can specify these actions using the variable
|
||||||
@code{mu4e-headers-actions}. Refer to @ref{Actions} for details.
|
@code{mu4e-headers-actions}. Refer to @ref{Actions} for details.
|
||||||
|
|
||||||
@t{mu4e} defines some default actions - one is @t{capture} - @key{a c} will
|
@t{mu4e} defines some default actions. One of this those is for
|
||||||
'capture' the current message. Next, when you're editing some message, you can
|
@emph{capturing} a message: @key{a c} will 'capture' the current
|
||||||
include the previously captured message as an attachment, using
|
message. Next, when you're editing some message, you can include the
|
||||||
|
previously captured message as an attachment, using
|
||||||
@code{mu4e-compose-attach-captured-message}.
|
@code{mu4e-compose-attach-captured-message}.
|
||||||
|
|
||||||
The file @file{mu4e-actions.el} in the @t{mu4e} source distribution contains a
|
The file @file{mu4e-actions.el} in the @t{mu4e} source distribution contains a
|
||||||
@ -1768,7 +1769,7 @@ available in your path.
|
|||||||
|
|
||||||
Then, when composing a message, you can use @t{M-x org-mu4e-compose-org-mode}
|
Then, when composing a message, you can use @t{M-x org-mu4e-compose-org-mode}
|
||||||
to enable this mode.
|
to enable this mode.
|
||||||
|
|
||||||
@t{org-mu4e-compose-org-mode} behaves more or less like a minor-mode. When it
|
@t{org-mu4e-compose-org-mode} behaves more or less like a minor-mode. When it
|
||||||
is active, editing the message body takes place in @t{org-mode}, while editing
|
is active, editing the message body takes place in @t{org-mode}, while editing
|
||||||
the headers uses the normal message editing mode, @t{mu4e-compose-mode}.
|
the headers uses the normal message editing mode, @t{mu4e-compose-mode}.
|
||||||
|
|||||||
Reference in New Issue
Block a user