mirror of https://github.com/djcb/mu.git
* fix mkdir / interaction with 'move-to-maildir'
This commit is contained in:
parent
8235efc5df
commit
a60ecb5284
|
@ -708,12 +708,16 @@ not provided, function asks for it."
|
|||
(interactive)
|
||||
(with-current-buffer mu4e-hdrs-buffer
|
||||
(let* ((target (or target (mu4e-ask-maildir "Move message to: ")))
|
||||
(target (if (string= (substring target 0 1) "/")
|
||||
target
|
||||
(concat "/" target)))
|
||||
(fulltarget (concat mu4e-maildir target)))
|
||||
(when (or (file-directory-p fulltarget)
|
||||
(and (yes-or-no-p
|
||||
(format "%s does not exist. Create now?" fulltarget))
|
||||
(mu4e-proc-mkdir fulltarget)))
|
||||
(mu4e-hdrs-mark 'move target)
|
||||
(sleep-for 1) ;; ugly
|
||||
(mu4e-hdrs-mark 'move target)
|
||||
(mu4e-next-header)))))
|
||||
|
||||
|
||||
|
|
|
@ -401,6 +401,10 @@ set to e.g. '/drafts'; if this works, we will receive (:info :path
|
|||
<path> :docid <docid>)."
|
||||
(mu4e-proc-send-command "add \"%s\" \"%s\"" path maildir))
|
||||
|
||||
(defun mu4e-proc-mkdir (maildir)
|
||||
"Update the message database for MAILDIR."
|
||||
(mu4e-proc-send-command "mkdir \"%s\"" maildir))
|
||||
|
||||
(defun mu4e-proc-save (docid partidx path)
|
||||
"Save attachment PARTIDX from message with DOCID to PATH."
|
||||
(mu4e-proc-send-command "save %d %d \"%s\"" docid partidx path))
|
||||
|
|
Loading…
Reference in New Issue