[![Contributors](https://img.shields.io/badge/Contributors-115-orange.svg)](#contributors)
[![Release](https://img.shields.io/github/release/neomutt/neomutt.svg)](https://github.com/neomutt/neomutt/releases/latest "Latest Release Notes")
[![License: GPL v2](https://img.shields.io/badge/License-GPL%20v2-blue.svg)](https://github.com/neomutt/neomutt/blob/master/COPYRIGHT)
-[![Travis branch](https://api.travis-ci.org/neomutt/neomutt.svg?branch=neomutt)](https://travis-ci.org/neomutt/neomutt)
+[![Code build](https://img.shields.io/travis/neomutt/neomutt.svg?label=code)](https://travis-ci.org/neomutt/neomutt)
[![Coverity Scan](https://img.shields.io/coverity/scan/8495.svg)](https://scan.coverity.com/projects/neomutt-neomutt)
+[![Website build](https://img.shields.io/travis/neomutt/neomutt.github.io.svg?label=website)](https://travis-ci.org/neomutt/neomutt.github.io)
## What is NeoMutt?
if (stat(tmp->path, &sb) != 0 || (S_ISREG(sb.st_mode) && sb.st_size == 0) ||
(!tmp->magic && (tmp->magic = mx_get_magic(tmp->path)) <= 0))
{
- /* if the mailbox still doesn't exist, set the newly created flag to
- * be ready for when it does. */
+ /* if the mailbox still doesn't exist, set the newly created flag to be
+ * ready for when it does. */
tmp->newly_created = true;
tmp->magic = 0;
tmp->size = 0;
}
}
- /* check to see if the folder is the currently selected folder
- * before polling */
+ /* check to see if the folder is the currently selected folder before polling */
if (!Context || !Context->path ||
((tmp->magic == MUTT_IMAP ||
#ifdef USE_NNTP
&& (fg == COLOR_DEFAULT || bg == COLOR_DEFAULT || object == MT_COLOR_TREE) &&
use_default_colors() != OK)
/* the case of the tree object is special, because a non-default
- * fg color of the tree element may be combined dynamically with
- * the default bg color of an index line, not necessarily defined in
- * a rc file.
- */
+ * fg color of the tree element may be combined dynamically with
+ * the default bg color of an index line, not necessarily defined in
+ * a rc file.
+ */
{
mutt_str_strfcpy(err->data, _("default colors not supported"), err->dsize);
return -1;
int rc;
/* RFC5322 mandates a From: header, so warn before bouncing
- * messages without one */
+ * messages without one */
if (h)
{
if (!h->env->from)
/**
* mutt_compose_menu - Allow the user to edit the message envelope
+ * @param msg Message to fill
+ * @param fcc Buffer to save FCC
+ * @param fcclen Length of FCC buffer
+ * @param cur Current message
+ * @param flags Flags, e.g. #MUTT_COMPOSE_NOFREEHEADER
* @retval 1 Message should be postponed
* @retval 0 Normal exit
* @retval -1 Abort message
*/
-int mutt_compose_menu(struct Header *msg, /* structure for new message */
- char *fcc, /* where to save a copy of the message */
- size_t fcclen, struct Header *cur, /* current message */
- int flags)
+int mutt_compose_menu(struct Header *msg, char *fcc, size_t fcclen,
+ struct Header *cur, int flags)
{
char helpstr[LONG_STRING];
char buf[LONG_STRING];
unsigned int mdlen;
/* Avoid CPU-intensive digest calculation if the certificates are
- * not even remotely equal.
- */
+ * not even remotely equal.
+ */
if (X509_subject_name_cmp(cert, peercert) != 0 || X509_issuer_name_cmp(cert, peercert) != 0)
return false;
(*extra)->disp_subj = NULL;
}
/* spam and user headers should never be hashed, and the new envelope may
- * have better values. Use new versions regardless. */
+ * have better values. Use new versions regardless. */
mutt_buffer_free(&base->spam);
mutt_list_free(&base->userhdrs);
MOVE_ELEM(spam);
}
#endif
/* decoding the attachment changes the size and offset, so save a copy
- * of the "real" values now, and restore them after processing
- */
+ * of the "real" values now, and restore them after processing
+ */
tmplength = b->length;
tmpoffset = b->offset;
/* if we are decoding binary bodies, we don't want to prefix each
- * line with the prefix or else the data will get corrupted.
- */
+ * line with the prefix or else the data will get corrupted.
+ */
save_prefix = s->prefix;
s->prefix = NULL;
*
* | Expando | Description
* |:--------|:-----------------------------------------------------------------
- * | \%a | Address of author
- * | \%A | Reply-to address (if present; otherwise: address of author
- * | \%b | Filename of the originating folder
+ * | \%a | Address of the author
+ * | \%A | Reply-to address (if present; otherwise: address of author)
+ * | \%b | Filename of the original message folder (think mailbox)
* | \%B | The list to which the letter was sent, or else the folder name (%b).
* | \%C | Current message number
- * | \%c | Size of message in bytes
+ * | \%c | Number of characters (bytes) in the message
* | \%D | Date and time of message using $date_format and local timezone
* | \%d | Date and time of message using $date_format and sender's timezone
* | \%e | Current message number in thread
* | \%E | Number of messages in current thread
- * | \%f | Entire from line
- * | \%F | Like %n, unless from self
+ * | \%F | Author name, or recipient name if the message is from you
+ * | \%f | Sender (address + real name), either From: or Return-Path:
+ * | \%g | Newsgroup name (if compiled with NNTP support)
* | \%g | Message tags (e.g. notmuch tags/imap flags)
* | \%Gx | Individual message tag (e.g. notmuch tags/imap flags)
* | \%H | Spam attribute(s) of this message
* | \%I | Initials of author
- * | \%i | Message-id
+ * | \%i | Message-id of the current message
* | \%J | Message tags (if present, tree unfolded, and != parent's tags)
* | \%K | The list to which the letter was sent (if any; otherwise: empty)
* | \%L | Like %F, except 'lists' are displayed first
* | \%l | Number of lines in the message
* | \%M | Number of hidden messages if the thread is collapsed
- * | \%m | Number of messages in the mailbox
- * | \%n | Name of author
- * | \%N | Score
+ * | \%m | Total number of message in the mailbox
+ * | \%N | Message score
+ * | \%n | Author's real name (or address if missing)
* | \%O | Like %L, except using address instead of name
- * | \%P | Progress indicator for builtin pager
+ * | \%P | Progress indicator for the built-in pager (how much of the file has been displayed)
* | \%q | Newsgroup name (if compiled with NNTP support)
* | \%R | Comma separated list of Cc: recipients
* | \%r | Comma separated list of To: recipients
- * | \%S | Short message status (e.g., N/O/D/!/r/-)
- * | \%s | Subject
- * | \%T | $to_chars
+ * | \%S | Single character status of the message (N/O/D/d/!/r/-)
+ * | \%s | Subject of the message
+ * | \%T | The appropriate character from the $$to_chars string
* | \%t | 'To:' field (recipients)
- * | \%u | User (login) name of author
- * | \%v | First name of author, unless from self
- * | \%W | Where user is (organization)
+ * | \%u | User (login) name of the author
+ * | \%v | First name of the author, or the recipient if the message is from you
+ * | \%W | Name of organization of author ('Organization:' field)
* | \%x | 'X-Comment-To:' field (if present and compiled with NNTP support)
* | \%X | Number of MIME attachments
- * | \%y | 'X-Label:' field (if present)
* | \%Y | 'X-Label:' field (if present, tree unfolded, and != parent's x-label)
+ * | \%y | 'X-Label:' field (if present)
* | \%Z | Combined message flags
* | \%zc | Message crypto flags
* | \%zs | Message status flags
* @page imap_imap IMAP network mailbox
*
* Support for IMAP4rev1, with the occasional nod to IMAP 4.
- *
- * | Data | Description
- * | :----------- | :-------------------------
- * | #mx_imap_ops | Mailbox callback functions
*/
#include "config.h"
mutt_str_strfcpy(scratch, NONULL((const char *) val->var), sizeof(scratch));
mutt_expand_path(scratch, sizeof(scratch));
/* MuttVars[idx].var is already 'char**' (or some 'void**') or...
- * so cast to 'void*' is okay */
+ * so cast to 'void*' is okay */
FREE((void *) MuttVars[idx].var);
*((char **) MuttVars[idx].var) = mutt_str_strdup(scratch);
break;
case DT_STRING:
{
/* MuttVars[idx].var is already 'char**' (or some 'void**') or...
- * so cast to 'void*' is okay */
+ * so cast to 'void*' is okay */
FREE((void *) MuttVars[idx].var);
*((char **) MuttVars[idx].var) = mutt_str_strdup((char *) val->var);
}
return 0;
/* NumMatched will _always_ be at least 1 since the initial
- * user-typed string is always stored */
+ * user-typed string is always stored */
if (numtabs == 1 && NumMatched == 2)
snprintf(Completed, sizeof(Completed), "%s", Matches[0]);
else if (numtabs > 1 && NumMatched > 2)
complete_all_nm_tags(pt);
/* All matches are stored. Longest non-ambiguous string is ""
- * i.e. don't change 'buffer'. Fake successful return this time.
- */
+ * i.e. don't change 'buffer'. Fake successful return this time.
+ */
if (UserTyped[0] == 0)
return true;
}
return false;
/* NumMatched will _always_ be at least 1 since the initial
- * user-typed string is always stored */
+ * user-typed string is always stored */
if (numtabs == 1 && NumMatched == 2)
snprintf(Completed, sizeof(Completed), "%s", Matches[0]);
else if (numtabs > 1 && NumMatched > 2)
return 0;
/* NumMatched will _always_ be at least 1 since the initial
- * user-typed string is always stored */
+ * user-typed string is always stored */
if (numtabs == 1 && NumMatched == 2)
snprintf(Completed, sizeof(Completed), "%s", Matches[0]);
else if (numtabs > 1 && NumMatched > 2)
** .dt %A .dd Reply-to address (if present; otherwise: address of author)
** .dt %b .dd Filename of the original message folder (think mailbox)
** .dt %B .dd The list to which the letter was sent, or else the folder name (%b).
- ** .dt %c .dd Number of characters (bytes) in the message
** .dt %C .dd Current message number
- ** .dt %d .dd Date and time of the message in the format specified by
- ** $$date_format converted to sender's time zone
- ** .dt %D .dd Date and time of the message in the format specified by
- ** $$date_format converted to the local time zone
+ ** .dt %c .dd Number of characters (bytes) in the message
+ ** .dt %D .dd Date and time of message using $date_format and local timezone
+ ** .dt %d .dd Date and time of message using $date_format and sender's timezone
** .dt %e .dd Current message number in thread
** .dt %E .dd Number of messages in current thread
- ** .dt %f .dd Sender (address + real name), either From: or Return-Path:
** .dt %F .dd Author name, or recipient name if the message is from you
+ ** .dt %f .dd Sender (address + real name), either From: or Return-Path:
** .dt %g .dd Newsgroup name (if compiled with NNTP support)
- ** .dt %g .dd Message labels (e.g. notmuch tags)
+ ** .dt %g .dd Message tags (e.g. notmuch tags/imap flags)
+ ** .dt %Gx .dd Individual message tag (e.g. notmuch tags/imap flags)
** .dt %H .dd Spam attribute(s) of this message
** .dt %I .dd Initials of author
** .dt %i .dd Message-id of the current message
+ ** .dt %J .dd Message tags (if present, tree unfolded, and != parent's tags)
** .dt %K .dd The list to which the letter was sent (if any; otherwise: empty)
- ** .dt %l .dd Number of lines in the message (does not work with maildir,
- ** Mh, and possibly IMAP folders)
** .dt %L .dd If an address in the ``To:'' or ``Cc:'' header field matches an address
** Defined by the users ``$subscribe'' command, this displays
** "To <list-name>", otherwise the same as %F
- ** .dt %m .dd Total number of message in the mailbox
+ ** .dt %l .dd Number of lines in the message (does not work with maildir,
+ ** Mh, and possibly IMAP folders)
** .dt %M .dd Number of hidden messages if the thread is collapsed
+ ** .dt %m .dd Total number of message in the mailbox
** .dt %N .dd Message score
** .dt %n .dd Author's real name (or address if missing)
** .dt %O .dd Original save folder where NeoMutt would formerly have
** If not sent to a list
** .dt %P .dd Progress indicator for the built-in pager (how much of the file has been displayed)
** .dt %q .dd Newsgroup name (if compiled with NNTP support)
- ** .dt %r .dd Comma separated list of ``To:'' recipients
** .dt %R .dd Comma separated list of ``Cc:'' recipients
- ** .dt %s .dd Subject of the message
+ ** .dt %r .dd Comma separated list of ``To:'' recipients
** .dt %S .dd Single character status of the message (``N''/``O''/``D''/``d''/``!''/``r''/``\(as'')
- ** .dt %t .dd ``To:'' field (recipients)
+ ** .dt %s .dd Subject of the message
** .dt %T .dd The appropriate character from the $$to_chars string
+ ** .dt %t .dd ``To:'' field (recipients)
** .dt %u .dd User (login) name of the author
** .dt %v .dd First name of the author, or the recipient if the message is from you
** .dt %W .dd Name of organization of author (``Organization:'' field)
** .dt %x .dd ``X-Comment-To:'' field (if present and compiled with NNTP support)
- ** .dt %X .dd Number of attachments
+ ** .dt %X .dd Number of MIME attachments
** (please see the ``$attachments'' section for possible speed effects)
- ** .dt %y .dd ``X-Label:'' field, if present
** .dt %Y .dd ``X-Label:'' field, if present, and \fI(1)\fP not at part of a thread tree,
** \fI(2)\fP at the top of a thread, or \fI(3)\fP ``X-Label:'' is different from
** Preceding message's ``X-Label:''
+ ** .dt %y .dd ``X-Label:'' field, if present
** .dt %Z .dd A three character set of message status flags.
** The first character is new/read/replied flags (``n''/``o''/``r''/``O''/``N'').
** The second is deleted or encryption flags (``D''/``d''/``S''/``P''/``s''/``K'').
** The third is either tagged/flagged (``\(as''/``!''), or one of the characters
** Listed in $$to_chars.
- ** .dt %zs .dd Message status flags
** .dt %zc .dd Message crypto flags
+ ** .dt %zs .dd Message status flags
** .dt %zt .dd Message tag flags
** .dt %{fmt} .dd the date and time of the message is converted to sender's
** time zone, and ``fmt'' is expanded by the library function
else if (CryptOpportunisticEncrypt)
{
/* When the message is not selected for signing or encryption, the toggle
- * between PGP/MIME and Traditional doesn't make sense.
- */
+ * between PGP/MIME and Traditional doesn't make sense.
+ */
if (msg->security & (ENCRYPT | SIGN))
{
snprintf(promptbuf, sizeof(promptbuf),
mutt_pretty_mailbox(fcc, fcclen);
/* note that x-mutt-fcc was present. we do this because we want to add a
- * default fcc if the header was missing, but preserve the request of the
- * user to not make a copy if the header field is present, but empty.
- * see http://dev.mutt.org/trac/ticket/3653
- */
+ * default fcc if the header was missing, but preserve the request of the
+ * user to not make a copy if the header field is present, but empty.
+ * see http://dev.mutt.org/trac/ticket/3653
+ */
code |= SENDPOSTPONEDFCC;
}
else if (((WithCrypto & APPLICATION_PGP) != 0) &&
snprintf(buf, sizeof(buf), "%s %s\r\n", Esmtp ? "EHLO" : "HELO", fqdn);
/* XXX there should probably be a wrapper in mutt_socket.c that
- * repeatedly calls conn->write until all data is sent. This
- * currently doesn't check for a short write.
- */
+ * repeatedly calls conn->write until all data is sent. This
+ * currently doesn't check for a short write.
+ */
if (mutt_socket_write(conn, buf) == -1)
return SMTP_ERR_WRITE;
return smtp_get_resp(conn);
* @page tags Driver based email tags
*
* Driver based email tags
- *
- * | Data | Description
- * | :------------- | :--------------------------------------------------
- * | #HiddenTags | Private tags which should not be displayed
- * | #TagTransforms | Lookup table of alternative tag names
- *
- * | Function | Description
- * | :-------------------------------- | :-----------------------------------------------
- * | driver_tags_free() | Free tags from a header
- * | driver_tags_getter() | Get transformed tags
- * | driver_tags_get_transformed() | Get transformed tags
- * | driver_tags_get() | Get tags
- * | driver_tags_get_with_hidden() | Get tags with hiddens
- * | driver_tags_get_transformed_for() | Get transformed tag for a tag name from a header
- * | driver_tags_add() | Add a tag to header
- * | driver_tags_replace() | Replace all tags
*/
#include "config.h"