Skip to main content

Mail

Struct Mail 

Source
pub struct Mail {
Show 68 fields pub folder: Option<String>, pub mailboxes: Vec<String>, pub sent: Option<String>, pub postponed: Option<String>, pub sendmail: Option<String>, pub editor: Option<String>, pub ispell: Option<String>, pub poll_seconds: Option<u64>, pub print: Option<String>, pub pipe_decode: Option<bool>, pub print_decode: Option<bool>, pub pipe_split: Option<bool>, pub print_split: Option<bool>, pub pipe_sep: Option<String>, pub save: Option<String>, pub forward: Option<String>, pub query_command: Option<String>, pub trash: Option<String>, pub edit_headers: Option<bool>, pub notmuch: Option<bool>, pub fast_reply: bool, pub quit: Option<String>, pub postpone: Option<String>, pub recall: Option<String>, pub confirmappend: bool, pub save_name: bool, pub force_name: bool, pub mark_old: Option<bool>, pub delete_untag: Option<bool>, pub flag_safe: bool, pub maildir_trash: bool, pub mail_check_recent: Option<bool>, pub sort_alias: Option<String>, pub shell: Option<String>, pub tmpdir: Option<String>, pub check_new: Option<bool>, pub print_confirm: Option<String>, pub alias_file: Option<String>, pub attribution: Option<String>, pub indent_string: Option<String>, pub forward_format: Option<String>, pub wrap_search: Option<bool>, pub simple_search: Option<String>, pub reply_regexp: Option<String>, pub include: Option<String>, pub forward_quote: bool, pub signature: Option<String>, pub sig_dashes: Option<bool>, pub sig_on_top: Option<bool>, pub hostname: Option<String>, pub user_agent: Option<bool>, pub abort_nosubject: Option<String>, pub abort_unmodified: Option<bool>, pub ask_cc: bool, pub ask_bcc: bool, pub autoedit: bool, pub copy: Option<bool>, pub lists: Vec<String>, pub subscribed: Vec<String>, pub alternates: Vec<String>, pub my_hdr: Vec<String>, pub metoo: bool, pub text_flowed: bool, pub new_mail_command: Option<String>, pub delete: Option<String>, pub abort_noattach: Option<String>, pub attach_keyword: Option<String>, pub undo_send: u64,
}

Fields§

§folder: Option<String>

mutt’s $folder: where mailboxes live, so =x and +x name a mailbox under it, at a prompt or in a macro. An IMAP account spec works too (“imap:work”), making =Archive mean imap:work/Archive.

§mailboxes: Vec<String>§sent: Option<String>§postponed: Option<String>§sendmail: Option<String>§editor: Option<String>§ispell: Option<String>

mutt’s $ispell: the spell checker the compose menu’s i runs over the draft, as ispell -x FILE. “ispell” when unset.

§poll_seconds: Option<u64>§print: Option<String>

Shell command the printed message is piped to (default lpr).

§pipe_decode: Option<bool>

mutt’s $pipe_decode: pipe the decoded message (brief headers, decoded body) rather than the raw one. Off by default.

§print_decode: Option<bool>

mutt’s $print_decode: print the decoded message. On by default, as in mutt.

§pipe_split: Option<bool>

mutt’s $pipe_split / $print_split: run the command once per tagged message instead of once over them all. Off by default.

§print_split: Option<bool>§pipe_sep: Option<String>

mutt’s $pipe_sep: what separates concatenated messages in one pipe run. Newline by default.

§save: Option<String>

Default target offered by s (save message to a mailbox).

§forward: Option<String>

“inline” (quoted text, the default) or “attach” (the original goes along as a message/rfc822 part, mutt’s mime_forward).

§query_command: Option<String>

mutt’s query_command: external address lookup for Tab completion at the To prompt (%s = the word, or appended), e.g. “khard email –parsable %s”.

§trash: Option<String>

mutt’s $trash: purged messages move here (a maildir path, or imap:account/folder of the open account) instead of being erased; purging inside the trash itself deletes for real.

§edit_headers: Option<bool>

mutt’s edit_headers (default false, like mutt): true puts the draft’s header block (From/To/Cc/Subject, Attach: lines) into the editor buffer. Off, the prompts set To/Subject and attachments go through the compose menu’s a.

§notmuch: Option<bool>

notmuch(1) search (X): false disables the key; unset/true leaves it on (notmuch itself must be installed; keep the database fresh with notmuch new in a hook or cron).

§fast_reply: bool

mutt’s $fast_reply: replies skip the To and Subject prompts, forwards skip Subject (the ask-yes questions still run).

§quit: Option<String>

mutt’s $quit: “yes” (the default) leaves at once, “no” refuses, “ask-yes” and “ask-no” ask first.

§postpone: Option<String>

mutt’s $postpone: leaving a draft. “ask-yes” (the default) and “ask-no” ask whether to postpone (else discard); “yes” postpones without asking, “no” discards without asking.

§recall: Option<String>

mutt’s $recall: composing when postponed drafts exist. “no” never offers to recall (always a new message); “yes” recalls the newest without asking; “ask-yes” / “ask-no” (the default is to ask) offer the new/recall choice.

§confirmappend: bool

mutt’s $confirmappend: ask before adding messages to a mailbox that already exists. Off by default, where mutt asks: rmut has never asked, and a save is one keystroke either way.

§save_name: bool

mutt’s $save_name: the default save target is the sender’s local part under $folder, when such a mailbox exists.

§force_name: bool

mutt’s $force_name: the same, whether or not it exists.

§mark_old: Option<bool>

mutt’s $mark_old: unread mail left behind in the mailbox ages to old (O in the index, out of the new count) when you leave. True unless set otherwise, as in mutt.

§delete_untag: Option<bool>

mutt’s $delete_untag: marking a tagged message for deletion (d, or a save) takes its tag off. True unless set otherwise, as in mutt.

§flag_safe: bool

mutt’s $flag_safe: a flagged message cannot be marked for deletion, by any of the ways of doing so. Off by default.

§maildir_trash: bool

mutt’s $maildir_trash: a purge gives deleted messages the maildir T flag instead of unlinking them; they stay in the index marked D. Maildir only. Off by default.

§mail_check_recent: Option<bool>

mutt’s $mail_check_recent: “new mail in X” only when X has grown since the last look. False announces any mailbox holding new mail, once, until it empties. True unless set otherwise.

§sort_alias: Option<String>

mutt’s $sort_alias: the order address completion offers alias expansions in: “address” (by the expansion, the default here), “alias” (by nick). “unsorted” reads as “alias”: the alias file is a map. A “reverse-” prefix flips it.

§shell: Option<String>

mutt’s $shell: what a bare ! (an empty shell command) runs interactively. $SHELL, then sh, when unset.

§tmpdir: Option<String>

mutt’s $tmpdir: where temporary files go (drafts on their way to the editor, parts on their way to a viewer). $TMPDIR, then /tmp, when unset.

§check_new: Option<bool>

mutt’s $check_new: look for mail delivered to the open maildir while it is open. False stops the rescan (IMAP is unaffected, as in mutt). True unless set otherwise.

§print_confirm: Option<String>

mutt’s $print: what p does. “ask-no” (the default) asks with Enter declining, “ask-yes” asks with Enter printing, “yes” prints without asking and “no” refuses to print at all.

§alias_file: Option<String>

mutt’s $alias_file: where aliases are read from and where create-alias appends. $RMUT_ALIASES, then ~/.config/rmut/aliases, when unset.

§attribution: Option<String>

mutt’s $attribution: the line a quoted reply opens with, over the message being replied to (%a address, %n name, %f the From header, %s subject, %i message-id, %d date, %{…} strftime).

§indent_string: Option<String>

mutt’s $indent_string: what each quoted line is prefixed with, "> " by default.

§forward_format: Option<String>

mutt’s $forward_format: the subject a forward carries, the same format string over the message being forwarded.

§wrap_search: Option<bool>

mutt’s $wrap_search: n wraps around the ends of the index. True by default, as in mutt; false stops at the last / first match instead.

§simple_search: Option<String>

mutt’s $simple_search: the template a bare-word search expands to, %s the word. Default ~f %s | ~s %s (from or subject), which is what a bare word already did; set it to add ~b %s for the body, say. Only a single word with no ~ expands.

§reply_regexp: Option<String>

mutt’s $reply_regexp: what a reply’s subject may already start with (“Re:” with an optional [n], by default). Replying takes it off and puts “Re: “ on, so prefixes never pile up; a locale’s own prefixes go in as ^(re|aw|sv):[ \t]*. Case-insensitive unless the regex has an uppercase letter, as mutt compiles it.

§include: Option<String>

mutt’s $include: quote the original in a reply? “ask-yes” (the default) and “ask-no” ask, “yes” and “no” decide it.

§forward_quote: bool

mutt’s $forward_quote: the forwarded text inside the “—– Forwarded message” markers is quoted with $indent_string, the way a reply is.

§signature: Option<String>

mutt’s $signature: a file whose contents end every new draft, or, when the name ends in |, a command whose output does. ~ is expanded. Unset (the default) appends nothing.

§sig_dashes: Option<bool>

mutt’s $sig_dashes: the signature is introduced by a line holding “– “. True unless set otherwise, as in mutt.

§sig_on_top: Option<bool>

mutt’s $sig_on_top: the signature goes above the quoted original rather than below it. Off by default, as in mutt.

§hostname: Option<String>

mutt’s $hostname: the host in a generated Message-ID. The system hostname when unset.

§user_agent: Option<bool>

mutt’s $user_agent: add a User-Agent: rmut/VERSION header to outgoing mail. Off by default, as neomutt has it.

§abort_nosubject: Option<String>

mutt’s $abort_nosubject: a draft with an empty subject. “ask-yes” (the default) asks with Enter aborting, “ask-no” asks with Enter sending it on, “yes” aborts without asking, “no” never asks.

§abort_unmodified: Option<bool>

mutt’s $abort_unmodified: the first editor pass came back with the body untouched, so the draft is dropped. True unless set otherwise, as in mutt; only the first edit is checked.

§ask_cc: bool

mutt’s $askcc / $askbcc: ask for those recipients when a draft is started, prefilled with what a group reply worked out.

§ask_bcc: bool§autoedit: bool

mutt’s $autoedit (needs edit_headers): skip every initial prompt and question, straight into the editor; the compose menu follows as usual.

§copy: Option<bool>

mutt’s $copy: false skips the sent copy (Fcc) entirely; an Fcc set in the compose menu still wins.

§lists: Vec<String>

mutt’s lists: address patterns naming mailing lists you know of. They drive ~l, the L list-reply target, and the Mail-Followup-To rmut sets on mail to a list.

§subscribed: Vec<String>

mutt’s subscribe: lists you are on. Subscribed lists count as known lists too, and a reply to one leaves your own address out of Mail-Followup-To, so the list copy is the only one you get.

§alternates: Vec<String>

mutt’s alternates: regexes matching your other addresses (aliases, an old domain, a role address). They join the identity addresses everywhere rmut asks “is this me?”: ~p and ~P, the +/T/C/F index marks, reverse_name, the group-reply dedup, and Mail-Followup-To.

§my_hdr: Vec<String>

mutt’s my_hdr: header lines added to every draft, e.g. “Organization: Acme” or “Bcc: me@example.com”. One naming a header rmut already wrote replaces it (so From: and Reply-To: win); To/Cc/Bcc gain the address instead.

§metoo: bool

mutt’s $metoo: keep your own address among a group reply’s recipients instead of dropping it.

§text_flowed: bool

mutt’s $text_flowed: outgoing text/plain is declared format=flowed and space-stuffed (RFC 3676), so a reader can rewrap it. The paragraphs themselves come from your editor, which has to leave a trailing space on a line that continues.

§new_mail_command: Option<String>

Shell command run when new mail arrives (neomutt’s new_mail_command): %f = the mailbox, %n = how many, e.g. “notify-send ‘rmut: %n new in %f’”. Fire-and-forget.

§delete: Option<String>

mutt’s $delete (a quadoption): what $ and quitting do with messages marked for deletion. “ask” (the default) asks, with Enter taking the yes; “yes” purges them without asking; “no” never purges, so the marks stay for a later change of mind.

§abort_noattach: Option<String>

neomutt’s $abort_noattach: what to do when the body mentions an attachment and none is attached. “no” (the default) never checks, “ask” asks before sending, “yes” refuses the send. neomutt’s ask-yes / ask-no both import as “ask”.

§attach_keyword: Option<String>

neomutt’s $abort_noattach_regex: what counts as mentioning one. Case-insensitive; the default is \b(attach|attached|attaching|attachment|attachments)\b.

§undo_send: u64

Seconds a sent message waits before it actually goes out, so z can take it back (rmut’s own; mutt sends at once). 0 is off. A held message is sent when the timer runs out or when rmut exits; batch sends (-s and friends) never hold.

Trait Implementations§

Source§

impl Clone for Mail

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Mail

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for Mail

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl<'de> Deserialize<'de> for Mail
where Mail: Default,

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more

Auto Trait Implementations§

§

impl Freeze for Mail

§

impl RefUnwindSafe for Mail

§

impl Send for Mail

§

impl Sync for Mail

§

impl Unpin for Mail

§

impl UnsafeUnpin for Mail

§

impl UnwindSafe for Mail

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.