Skip to content

Commit

Permalink
doc: updates
Browse files Browse the repository at this point in the history
  • Loading branch information
djcb committed Dec 17, 2024
1 parent 88e4bea commit 407c618
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 18 deletions.
33 changes: 19 additions & 14 deletions mu4e/mu4e-folders.el
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
;;; mu4e-folders.el --- Dealing with maildirs & folders -*- lexical-binding: t -*-
;;; mu4e-folders.el --- Maildirs & folders -*- lexical-binding: t -*-

;; Copyright (C) 2021-2023 Dirk-Jan C. Binnema
;; Copyright (C) 2021-2024 Dirk-Jan C. Binnema

;; Author: Dirk-Jan C. Binnema <[email protected]>
;; Maintainer: Dirk-Jan C. Binnema <[email protected]>
Expand Down Expand Up @@ -28,20 +28,26 @@
(require 'mu4e-helpers)
(require 'mu4e-context)
(require 'mu4e-server)


;;; Customization
(defgroup mu4e-folders nil
"Special folders."
:group 'mu4e)

(defcustom mu4e-drafts-folder "/drafts"
"Folder for draft messages, relative to the root maildir.
For instance, \"/drafts\". Instead of a string, may also be a
function that takes a message (a msg plist, see
`mu4e-message-field'), and returns a folder. Note, the message
parameter refers to the original message being replied to / being
forwarded / re-edited and is nil otherwise. `mu4e-drafts-folder'
is only evaluated once."
For instance, \"/drafts\".
Instead of a string, may also be a function that takes a
message (a msg plist, see `mu4e-message-field'), and returns a
folder. Note, the message parameter refers to the original
message being replied to / being forwarded / re-edited and is nil
otherwise. `mu4e-drafts-folder' is only evaluated once.
The form of draft messages is not necessarily compatible with
other e-mail programs, e.g. when it involves attachments and the
like.
"
:type '(choice
(string :tag "Folder name")
(function :tag "Function return folder name"))
Expand Down Expand Up @@ -98,8 +104,7 @@ Each of the list elements is a plist with at least:
Optionally, you can add the following:
`:name' - name of the maildir to be displayed in main-view.
`:hide' - if t, the shortcut is hidden from the main-view and
speedbar.
`:hide' - if t, the shortcut is hidden from the main-view.
`:hide-unread' - do not show the counts of unread/total number
of matches for the maildir in the main-view, and is implied
from `:hide'.
Expand Down Expand Up @@ -162,7 +167,7 @@ mime-type are nil."
(defvar mu4e-maildir-list nil
"Cached list of maildirs.")



(defun mu4e-maildir-shortcuts ()
"Get `mu4e-maildir-shortcuts' in the (new) format.
Converts from the old format if needed."
Expand Down Expand Up @@ -284,8 +289,8 @@ Offer to create it if it does not exist yet."
This is based on the variable `mu4e-attachment-dir', which is either:
- if is a string, used it as-is
- a function taking two string parameters, both of which can be nil:
(1) a filename or a URL
(2) a mime-type (such as \"text/plain\"."
(1) FNAME, a filename or a URL
(2) MIMETYPE, a mime-type (such as \"text/plain\"."
(let ((dir
(cond
((stringp mu4e-attachment-dir)
Expand Down
7 changes: 3 additions & 4 deletions mu4e/mu4e.texi
Original file line number Diff line number Diff line change
Expand Up @@ -523,10 +523,9 @@ If the mail-retrieval process returns with a non-zero exit code,
is set to @code{nil}), but then try to index your maildirs anyway
(unless @code{mu4e-index-update-error-continue} is set to @code{nil}).

Reason for these defaults is that some of the mail-retrieval programs
may return non-zero, even when the updating process succeeded; however,
it is hard to tell such pseudo-errors from real ones like `login
failed'.
Reason for these defaults is that some of the mail-retrieval programs may return
non-zero, even when the updating process succeeded; however, it is hard to tell
such pseudo-errors from real ones like @t{login failed}.

If you need more refinement, it may be useful to wrap the mail-retrieval
program in a shell-script, for example @t{fetchmail} returns 1 to
Expand Down

0 comments on commit 407c618

Please sign in to comment.