Skip to content

Instantly share code, notes, and snippets.

@ahelja
Last active November 21, 2020 08:21
Show Gist options
  • Save ahelja/0e08b7404c8abb8fa49c to your computer and use it in GitHub Desktop.
Save ahelja/0e08b7404c8abb8fa49c to your computer and use it in GitHub Desktop.
Mutt run commands
#General --------------------------
set realname = 'Name Surname'
set from = 'username@domain.com'
set imap_user = 'username@domain.com'
set imap_pass = 'password'
set folder = 'imaps://imap.gmail.com:993'
set spoolfile = '+INBOX'
set postponed = '+[Gmail]/Drafts'
set trash = 'imaps://imap.gmail.com/[Gmail]/Trash'
set header_cache = '~/.mutt/cache/headers'
set message_cachedir = '~/.mutt/cache/bodies'
set certificate_file = '~/.mutt/certificates'
set smtp_url = 'smtp://username@domain.com@smtp.gmail.com:587/'
set smtp_pass = 'password'
set move = no
set markers = no
set imap_check_subscribed
bind editor <space> noop
set wait_key = no
set delete
unset confirmappend
set timeout=15
set mail_check=60
set imap_passive = no
set check_new=yes
set imap_keepalive = 900
set header_cache=~/.hcache
# Normal stuff ----------
auto_view text/html
set editor="vim +startinsert +':set textwidth=0'"
set fast_reply = yes
set abort_nosubject = no
set abort_unmodified = ask-yes
set reply_self = no # Reply to recipients, not to myself on my own msgs
set indent_string = "> "
set include = yes
set bounce_delivered = yes
set forward_format = "Fwd: [ %s ]"
set forward_quote = yes
set metoo=yes
# Status Bar -----------------------------------------
set status_chars = " *%A"
set status_format = "───[ Folder: %f ]───[%r%m messages%?n? (%n new)?%?d? (%d to delete)?%?t? (%t tagged)? ]───%>─%?p?( %p postponed )?───"
unset mark_old
# Index View Options ---------------------------------
folder-hook . set sort=threads
folder-hook =MuttMail/sent set sort=date-sent
set sort_aux = reverse-date-sent
set strict_threads = no
set wrap_search = yes
set mark_old = no # Do not mark unread new messages as 'old'
set collapse_unread = no # Do not let me collapse threads with unread msgs
set uncollapse_jump = yes # When uncollapsing, jump to new msgs
# keyboard bindings
bind index <tab> sync-mailbox
bind index <space> collapse-thread
macro index <esc>m "T~N<enter>;WNT~O<enter>;WO\CT~T<enter>" "mark all messages read"
macro index gi '<change-folder>=INBOX<enter>' 'Go to Inbox'
macro index ga '<change-folder>=[Gmail]/All Mail<enter>' 'Go to All Mail'
macro index gs '<change-folder>=[Gmail]/Sent Mail<enter>' 'Go to Sent Mail'
macro index gd '<change-folder>=[Gmail]/Drafts<enter>' 'Go to Drafts'
macro index gx '<change-folder>=[Gmail]/Spam<enter>' 'Go to Spam'
macro index gd '<change-folder>=[Gmail]/Trash<enter>' 'Go to Trash'
macro index,pager y "<enter-command>unset trash\n <delete-thread>" "Gmail archive message"
macro index,pager d "<enter-command>set trash=\"imaps://imap.googlemail.com/[Gmail]/Trash\"\n <delete-thread>" "Gmail delete message"
# sidebar settings
set sidebar_visible = no
macro index b '<enter-command>toggle sidebar_visible<enter><refresh>'
macro pager b '<enter-command>toggle sidebar_visible<enter><redraw-screen>'
# Contacts (google goobook)
set query_command="goobook query '%s'"
macro index,pager a "<pipe-message>goobook add<return>" "add sender to google contacts"
bind editor <Tab> complete-query
macro index <esc>m "T~N<enter>;WNT~O<enter>;WO\CT~T<enter>" "mark all messages read"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment