with folders located on a remote IMAP server.
You can access the remote inbox by selecting the folder
-<tt/{imapserver}inbox/, where <tt/imapserver/ is the name of the IMAP
-server and <tt/inbox/ is the special name for your spool mailbox on
+<tt>imap://imapserver/INBOX</tt>, where <tt/imapserver/ is the name of the
+IMAP server and <tt/INBOX/ is the special name for your spool mailbox on
the IMAP server. If you want to access another mail folder at the IMAP
-server, you should use <tt>{imapserver}path/to/folder</tt> where
+server, you should use <tt>imap://imapserver/path/to/folder</tt> where
<tt>path/to/folder</tt> is the path of the folder you want to access.
You can select an alternative port by specifying it with the server, ie:
-<tt/{imapserver:port}inbox/.
+<tt>imap://imapserver:port/INBOX</tt>.
You can also specify different username for each folder, ie:
-<tt/{username@imapserver[:port]}inbox/.
+<tt>imap://username@imapserver[:port]/INBOX</tt>.
If Mutt was compiled with SSL support (by running the <em/configure/
script with the <em/--with-ssl/ flag), connections to IMAP servers
can be encrypted. This naturally requires that the server supports
SSL encrypted connections. To access a folder with IMAP/SSL, you should
-use <tt>{[username@]imapserver[:port]/ssl}path/to/folder</tt> as your
+use <tt>imaps://[username@]imapserver[:port]/path/to/folder</tt> as your
folder path.
+Pine-compatible notation is also supported, ie
+<tt>{[username@]imapserver[:port][/ssl]}path/to/folder</tt>
+
Note that not all servers use / as the hierarchy separator. Mutt should
correctly notice which separator is being used by the server and convert
paths accordingly.
When browsing folders on an IMAP server, you can toggle whether to look
at only the folders you are subscribed to, or all folders with the
<em/toggle-subscribed/ command. See also the
-<ref id="imap_list_subscribed" name="$imap_list_subscribed"> variable.
+<ref id="imap_list_subscribed"
+name="$imap_list_subscribed"> variable.
Polling for new mail on an IMAP server can cause noticeable delays. So, you'll
want to carefully tune the
<item><ref id="imap_pass" name="$imap_pass"> - a
password which you may preset, used by all authentication methods where
a password is needed.
+<item><ref id="imap_authenticators"
+ name="$imap_authenticators"> - a colon-delimited list of IMAP
+ authentication methods to try, in the order you wish to try them. If
+ specified, this overrides mutt's default (attempt everything, in the order
+ listed above).
</itemize>
<sect1>Start a WWW Browser on URLs (EXTERNAL)<label id="urlview">
{
imap_auth_t* authenticator;
char* methods;
- char* comma; /* should be colon ;-) */
char* method;
+ char* delim;
int r = -1;
if (ImapAuthenticators && *ImapAuthenticators)
{
/* Try user-specified list of authentication methods */
methods = safe_strdup (ImapAuthenticators);
- method = methods;
- while (method)
+ for (method = methods; method; method = delim)
{
- comma = strchr (method, ':');
- if (comma)
- *comma++ = '\0';
+ delim = strchr (method, ':');
+ if (delim)
+ *delim++ = '\0';
+ if (! method[0])
+ continue;
+
dprint (2, (debugfile, "imap_authenticate: Trying method %s\n", method));
authenticator = imap_authenticators;
authenticator++;
}
-
- method = comma;
}
FREE (&methods);
mutt_message (_("Marking %d messages deleted..."), deleted);
snprintf (tmp, sizeof (tmp), "UID STORE %s +FLAGS.SILENT (\\Deleted)",
buf);
+ /* mark these messages as unchanged so second pass ignores them. Done
+ * here so BOGUS UW-IMAP 4.7 SILENT FLAGS updates are ignored. */
+ for (n = 0; n < ctx->msgcount; n++)
+ if (ctx->hdrs[n]->deleted && ctx->hdrs[n]->changed)
+ ctx->hdrs[n]->active = 0;
if (imap_exec (idata, tmp, 0) != 0)
- /* continue, let regular store try before giving up */
- dprint(2, (debugfile, "imap_sync_mailbox: fast delete failed\n"));
- else
- /* mark these messages as unchanged so second pass ignores them */
- for (n = 0; n < ctx->msgcount; n++)
- if (ctx->hdrs[n]->deleted && ctx->hdrs[n]->changed)
- ctx->hdrs[n]->changed = 0;
+ {
+ mutt_error (_("Expunge failed"));
+ mutt_sleep (1);
+ rc = -1;
+ goto out;
+ }
}
}
{
if (ctx->hdrs[n]->changed)
{
+ ctx->hdrs[n]->changed = 0;
+
mutt_message (_("Saving message status flags... [%d/%d]"), n+1,
ctx->msgcount);
snprintf (buf, sizeof (buf), "UID STORE %d FLAGS.SILENT (%s)",
HEADER_DATA (ctx->hdrs[n])->uid, flags);
+ /* dumb hack for bad UW-IMAP 4.7 servers spurious FLAGS updates */
+ ctx->hdrs[n]->active = 0;
+
/* after all this it's still possible to have no flags, if you
* have no ACL rights */
if (*flags && (imap_exec (idata, buf, 0) != 0) &&
}
}
- ctx->hdrs[n]->changed = 0;
+ ctx->hdrs[n]->active = 1;
}
}
ctx->changed = 0;