Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
194 lines (176 sloc) 7.7 KB
# vim:ts=3:et:ft=muttrc
#
# mutt 1.5 (with sidebar patch) config
# joshua stein <jcs@jcs.org>
#
# things to set
set ascii_chars=no
set alias_file=~/.muttrc.aliases
set attach_format="%u%D%I %t%2n %T%.20d %> [%.7m/%.10M, %.6e%?C?, %C?, %s] "
set confirmappend=no
set connect_timeout=3
set date_format="!%a, %d %b %Y at %H:%M:%S %Z"
set delete=yes
set editor="vim"
set fast_reply=yes
set folder=~/Mail # overridden by imap
set forward_format="fwd: %s"
set header_cache=~/.mutt-cache/
set include=yes
set index_format="%[!%m%d] [%Z] %-54.54s %F"
set ispell="aspell --mode=email --add-email-quote=%,#,:,} --check"
set mail_check=60
set mark_old=no
set markers=no
set menu_context=1
set message_cache_clean=yes
set message_cachedir=~/.mutt-cache/
set metoo=no
set mime_forward=ask-no
set move=no
set narrow_tree=yes
set pager_context=2
set pager_stop=yes
set pager_format=" %f: %s"
set pipe_decode=yes
set postpone=ask-no
set postponed="=postponed"
set print=ask-no
set query_command="/usr/local/bin/lbdbq '%s'"
set quit=ask-yes
set read_inc=100
set record="=sent"
set sendmail="msmtp"
set sidebar_divider_char="| "
set sidebar_format="%B%* %?N?(%N)?"
set sidebar_visible=yes
set sidebar_width=18
set smart_wrap=yes
set sort=threads
set status_format=" %h: %f (msgs:%?M?%M/?%m %l%?n? new:%n?%?o? old:%o?%?d? del:%d?%?F? flag:%F?%?t? tag:%t?%?p? post:%p?%?b? inc:%b?%?l??) %> %_v "
set status_on_top=yes
set tilde=yes
set timeout=15
set use_envelope_from=yes
set use_from
unset user_agent
# things to bind keys to
bind attach <left> exit
bind pager <down> next-line
bind pager <up> previous-line
bind pager <left> exit
bind pager <right> next-entry
bind pager \CF next-page
bind pager \CB previous-page
bind pager \CP print-message
bind index <down> next-entry
bind index j next-entry
bind index <up> previous-entry
bind index k previous-entry
bind index <delete> delete-message
bind index <space> display-message
bind index <right> display-message
bind index <tab> next-unread
bind index \CF next-page
bind index \CB previous-page
bind compose F edit-from
# always run $query_command when completing addresses instead of requiring C-t
bind editor <tab> complete-query
# act like normal vi keys but browse sidebar folders
macro index K "<enter-command>push <sidebar-prev><sidebar-open><enter>"
macro index J "<enter-command>push <sidebar-next><sidebar-open><enter>"
# things to automate
macro index,pager i "<change-folder>!<enter>" "go home"
macro index,pager n "<change-folder><enter>" "go to box with new mail"
macro index,pager p "<change-folder><up><up><enter>" "go back to the previous mailbox"
macro index D "<tag-pattern>~d >1m<enter><tag-prefix-cond><delete-message>" "delete old mail"
# do a one-time reply with sig on top, for e-mail chains where everyone else
# is doing annoying top-replying
macro index,pager R "<enter-command>set sig_on_top=yes<enter><reply><enter-command>set sig_on_top=no<enter>"
macro index,pager G "<enter-command>set sig_on_top=yes<enter><group-reply><enter-command>set sig_on_top=no<enter>"
# imitate the old search-body function, but expensive for imap
macro index <Esc>b "<search>~B " "search in message bodies"
# sidebar shenanigans
macro index B '<enter-command>toggle sidebar_visible<enter><refresh><enter>'
macro pager B '<enter-command>toggle sidebar_visible<enter><redraw-screen><enter>'
# things to happen
folder-hook . set sort=threads # everything else
folder-hook . set strict_threads=no # compensate for stupid clients
folder-hook . set sort_aux=last-date-received # bumped threads appear new
folder-hook sent set strict_threads=yes # don't group incorrectly
folder-hook sent set sort=date-sent # when did i send that?
folder-hook allmail.* set sort=mailbox-order # don't sort, for fast loading
folder-hook allmail.* push <toggle-write> # don't save changes, read-only
# create message-ids that don't leak private info (like the number of messages
# sent in the current mutt session, or the local hostname)
send-hook . 'my_hdr Message-ID: <`date +"%Y%m%d%H%M%S"`.`sh -c "dd if=/dev/urandom bs=500 count=1 2>/dev/null | md5 | dd if=/dev/stdin bs=10 count=1 2>/dev/null"`@`sh -c "dd if=/dev/urandom bs=500 count=1 2>/dev/null | md5 | dd if=/dev/stdin bs=15 count=1 2>/dev/null"`>'
# things to display (or not)
ignore *
unignore from: resent-from: sender: reply-to: to: resent-to: cc: bcc: x-mailing-list: date: resent-date: organization: organisation: x-mailer: x-newsreader: x-agent: x-editor: user-agent: priority: importance: message-id: resent-message-id: subject: old-return-receipt-to: old-disposition-notification-to:
unhdr_order *
hdr_order from: resent-from: sender: reply-to: to: resent-to: cc: bcc: x-mailing-list: date: resent-date: organization: organisation: x-mailer: x-newsreader: x-agent: x-editor: user-agent: priority: importance: message-id: resent-message-id: old-return-receipt-to: old-disposition-notification-to: subject:
# bold/underline-only styling, for old non-color xterm (now xterm-r6 $TERM)
mono attachment bold
mono body underline "(https?|t?ftp|mailto|gopher|ssh|telnet|finger)://[^ ]+"
mono body underline "[-a-z_0-9.]+@[-a-z_0-9.]+[a-z]" # email addresses
mono body bold "-----Original Message-----"
mono body bold "[;:]-[)/(|]"
mono header none .
mono header bold "^From: "
mono header bold "^Resent-From: "
mono header bold "^To: "
mono header bold "^Subject: "
mono header bold "^Organi[zs]ation: "
mono header bold "^Priority: Urgent"
mono header bold "^Importance: high"
mono index bold '~U'
mono index bold '~F'
mono indicator reverse
mono signature bold
mono sidebar_new bold
mono tilde bold
mono tree bold
mono quoted bold
# since i now have to use an xterm-color $TERM, init color versions of the
# same using brightcolor16 as a bright black
color normal default default # init to black-on-white
color attachment brightdefault default
color body brightdefault default "(http|https|ftp|mailto|gopher|telnet|finger)://[^ ]+"
color body brightdefault default "[-a-z_0-9.]+@[-a-z_0-9.]+[a-z]"
color body brightdefault default "-----Original Message-----"
color body brightdefault default "[;:]-[)/(|]"
color header default default .
color header brightdefault default "^From: "
color header brightdefault default "^Resent-From: "
color header brightdefault default "^To: "
color header brightdefault default "^Subject: "
color header brightdefault default "^Organi[zs]ation: "
color header brightdefault default "^Priority: Urgent"
color header brightdefault default "^Importance: high"
color header brightdefault default '~U'
color header brightdefault default '~F'
color signature brightdefault default
color sidebar_new brightdefault default
color tilde brightblack default
color tree color242 default
color quoted brightblack default
# color flagged a dark red
color index brightcolor160 default '~F'
# color to-be-deleted as grayed out
color index brightblack default '~D'
# bold new email in the index
color index brightdefault default '~U'
# make huge messages stand out so i can avoid downloading them
color index brightcolor19 default '~z 500000-'
# things i can see in mutt (with external programs through ~/.mailcap)
auto_view application/pgp-encrypted
auto_view application/pgp-keys
auto_view application/pgp-signature
auto_view text/html # html with lynx
auto_view application/msword # .doc with antiword
# but that doesn't mean i don't like text/plain
alternative_order text/plain text/html
# things to load in
source ~/.muttrc.personal # my personal stuff
source ~/.muttrc.lists # mailboxes, folders
source $alias_file # for tab completion