# /etc/mail.rc
# Configuration file for Mail(1)

## The standard POSIX 2008/Cor 1-2013 mandates the following initial settings:
# [a]   noallnet, noappend, asksub, noaskbcc, noaskcc, noautoprint,
# [b-e] nobang, nocmd, nocrt, nodebug, nodot, escape="~",
# [f-i] noflipr, nofolder, header, nohold, noignore, noignoreeof,
# [j-o] nokeep, nokeepsave, nometoo, nooutfolder,
# [p-r] nopage, prompt="? ", noquiet, norecord,
# [s]   save, nosendwait, noshowto, nosign, noSign,
# [t-z] toplines="5"
# Notes:
# - *noonehop* doesn't exist in this implementation.
#   To pass through options to the MTA, use the `-O' command line option
# - *prompt* is "\\& " by default, which will act POSIX-compliant
#   unless the user would set *bsdcompat*

## The remaining content adjusts the standard-imposed default settings.
# Note that some of the following flags are specific to S-nail(1) and may thus
# not work with other Mail(1) / mailx(1) programs.
# Entries are marked [OPTION] if their availability is compile-time dependent

# If threaded mode is activated, automatically collapse thread
set autocollapse

# Enter threaded mode automatically
#set autothread autosort=thread

# Append rather than prepend when writing to mbox automatically.
# This has no effect unless *hold* is unset again
set append

# Ask for a message subject.
set ask

# Slightly more "BSDish" behaviour: traditional flag display in the header
# summary; *bsdannounce* prints a header summary on folder change and thus
# complements *header* on a per-folder basis (it is meaningless unless
# *header* is set)
set bsdflags bsdannounce

# In order to get coloured output in $PAGER, this must be set.
# (Coloured output is only used if $TERM is found in *colour-terms*)
#set colour-pager

# Assume a CRT-like terminal and invoke a $PAGER
set crt

# Define date display in header summary
#set datefield="%R %m-%d" datefield-markout-older="   %g-%m-%d"

# When composing messages a line consisting of `.' finalizes a message
set dot

# Immediately start $EDITOR (or $VISUAL) when composing a message
#set editalong

# Do not remove empty private mail folders
set emptybox

# Startup into interactive mode even if the (given) mailbox is empty
#set emptystart

# [OPTION] Add more entries to the history as is done by default
set history-gabby

# Do not forward to mbox by default since this is likely to be
# irritating for most users today
set hold

# Quote the original message in replies by "> " as usual on the Internet
set indentprefix="> "

# Mark messages that have been answered
set markanswered

# Try to circumvent false or missing MIME Content-Type descriptions
set mime-counter-evidence

# Control loading of mime.types(5) file: the value may be a combination of the
# letters "s" and "u": if "u" is seen ~/.mime.types will be loaded if possible;
# "s" adds /etc/mime.types, if available; setting this without any value uses
# only a set of builtin mimetypes; the default behaviour equals "us".
#set mimetypes-load-control

# Do not remove empty mail folders in the spool directory.
# This may be relevant for privacy since other users could otherwise create
# them with different permissions
set keep

# When writing mailbox files we strip Content-Length: and Lines: header fields
# from edited / changed messages, because S-nail doesn't deal with these
# (non-standard) fields -- and since other MUAs may rely on their content, if
# present, it seems more useful to strip them than to keep them, now that they
# became invalid; set this to include them nonetheless
#set keep-content-length

# A nice prompt for ISO 6429/ECMA-48 terminals
#set prompt="\033[31m?\?[\$ \@]\& \033[0m"

# Automatically quote the text of the message that is responded to
set quote

# On group replies, specify only the sender of the original mail in  To: and
# mention it's other recipients in the secondary Cc: instead of placing them
# all together in To:
set recipients-in-cc

# When responding to a message, try to answer in the same character set
#set reply-in-same-charset

# [OPTION] Outgoing messages are sent in ISO-8859-1 if all their characters
# are representable in it, otherwise in UTF-8.
# Note: it is highly advisable to read the section "Character sets" of the
# manual in order to understand all the possibilities that exist to fine-tune
# charset usage (variables also of interest: *ttycharset*, *charset-8bit*,
# *sendcharsets-else-ttycharset*; and of course we inherit the $LC_CTYPE /
# $LC_ALL / $LANG environment variables and react upon them)
set sendcharsets=iso-8859-1,utf-8

# Display sender's real names in header summaries
set showname

# Show recipients of messages sent by the user himself in header summaries
set showto

# Hide some header fields which are uninteresting for most human readers
ignore received in-reply-to message-id references
ignore mime-version content-transfer-encoding

# Only include selected header fields when forwarding messages.
fwdretain subject date from to

# Unfortunately some mime.types(5) that are really text were assigned to
# `application/xy' rather than to `text/xy'.
# The special pipe command `@' will force treatment of an attachment as plain
# text, so add some rather useful of those
set pipe-application/javascript=@
set pipe-application/json=@
set pipe-application/mbox=@
set pipe-application/pgp-signature=@
set pipe-application/x-csh=@
set pipe-application/x-latex=@
set pipe-application/x-perl=@
set pipe-application/x-sh=@
set pipe-application/x-shar=@
set pipe-application/x-tex=@
set pipe-application/x-texinfo=@
set pipe-application/x-xfig=@
set pipe-application/xhtml+xml=@
set pipe-application/xml=@
set pipe-application/xml-dtd=@
set pipe-application/xslt+xml=@
set pipe-image/svg+xml=@

# Other pipe-CONTENT/SUBCONTENT entries
#set pipe-text/html="lynx -stdin -dump -force_html"

