Skip to content

Instantly share code, notes, and snippets.

@roguesherlock
Created September 24, 2016 07:06
Show Gist options
  • Save roguesherlock/1a46013749cdaa90273c7467f4979404 to your computer and use it in GitHub Desktop.
Save roguesherlock/1a46013749cdaa90273c7467f4979404 to your computer and use it in GitHub Desktop.
muttrc file for gmail. passwords encrypted with keybase
source "keybase decrypt -i ~/.mutt/passwords.keybase |"
##
## Main
##
set editor = "emacs"
set from = "0xelectron <0xproton@gmail.com>"
set edit_headers = yes
set imap_user = "0xproton@gmail.com"
set imap_keepalive = 30
unset imap_passive # allow mutt to open new imap connection automatically
set folder = "imaps://imap.gmail.com"
set spoolfile = "+INBOX"
set postponed = "+[Gmail]/Drafts"
set header_cache = ~/.mutt/0xproton/headers
set message_cachedir = ~/.mutt/0xproton/bodies
set certificate_file = ~/.mutt/certificates
set smtp_url = "smtp://0xproton@smtp.gmail.com:587/"
set move = no
set quit = ask-yes # confirm before quitting
set wait_key = no # Don't ask me to press a key to continue after I did a shell escape and came back
set mbox_type = Maildir # mailbox type
set delete # don't ask, just do
unset confirmappend # When saving a message, append the message to an existing mailbox without asking (Why should it ask, anyway? Mailboxes generally have multiple messages...)
unset mark_old # read/new is good enough for me
set beep_new # bell on new mails
set pipe_decode # strip headers and eval mimes when piping
set thorough_search # strip headers and eval mimes before searching
##
## Macros
##
macro index,pager I O "Mark as read"
macro index,pager U O "Mark as unread"
macro index,pager ga "=[Gmail]/All Mail" "Go to all mail"
macro index,pager gs =[Gmail]/Starred "Go to 'Starred'"
macro index,pager gd =[Gmail]/Drafts "Go to 'Drafts'"
macro index,pager gl ? "Go to 'Label'"
macro index,pager gi =INBOX "Go to inbox"
macro index,pager gt "=[Gmail]/Sent Mail" "Go to 'Sent Mail'"
macro index,pager d "=[Gmail]/Trash" "Trash"
macro index,pager + =[Gmail]/Important "Mark as important"
macro index,pager ! =[Gmail]/Spam "Report spam"
macro index,pager e "=[All]/Gmail Mail" "Archive conversation"
folder-hook +INBOX 'macro index,pager y "=[Gmail]/All Mail" "Archive conversation"'
folder-hook +[Gmail]/Trash macro index,pager y =INBOX "Move to inbox"
folder-hook +[Gmail]/Starred bind index,pager y flag-message #"Toggle star"
##
## Shortcuts
##
#bind editor noop
bind index,pager c mail # compose
bind generic x tag-entry # Select Conversation
bind index x tag-thread # Select Conversation
bind pager x tag-message # Select Conversation
bind index,pager s flag-message # Star a message
bind index,pager a group-reply # Reply all
bind index,pager \# delete-thread # Delete
bind index,pager l copy-message # Label
bind index,pager v save-message # Move to
##
## Network Timeouts
##
set timeout = 60 # idle time before scanning
set mail_check = 60 # minimum time between scans
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment