Skip to content

Instantly share code, notes, and snippets.

@neutraltone
Created September 21, 2017 12:13
Show Gist options
  • Save neutraltone/99a60aa58111f3f086f20039e8401154 to your computer and use it in GitHub Desktop.
Save neutraltone/99a60aa58111f3f086f20039e8401154 to your computer and use it in GitHub Desktop.
Mutt Gmail Configuration
# Me
set from = "EMAIL@gmail.com"
set realname = "NAME"
# My credentials
# For 2FA issue and application token from:
# https://security.google.com/settings/security/apppasswords
set smtp_url = "smtp://EMAIL@gmail.com@smtp.gmail.com:587/"
set smtp_pass = "password"
set imap_user = "EMAIL@gmail.com"
set imap_pass = "password"
# My mailboxes
set folder = "imaps://imap.gmail.com:993"
set spoolfile = "+INBOX"
set postponed = "+[Gmail]/Drafts"
# Where to put the stuff
set header_cache = "~/.mutt/cache/headers"
set message_cachedir = "~/.mutt/cache/bodies"
set certificate_file = "~/.mutt/certificates"
# Etc
set mail_check = 30
set move = no
set imap_keepalive = 900
set sort = threads
set editor = "vim"
set smtp_authenticators = 'gssapi:login'
# GnuPG bootstrap
# source ~/.mutt/gpg.rc
# Gmail-style keyboard shortcuts
macro index,pager ga "<change-folder>=[Gmail]/All<tab><enter>" "Go to all mail"
macro index,pager gi "<change-folder>=INBOX<enter>" "Go to inbox"
macro index,pager gs "<change-folder>=[Gmail]/Starred<enter>" "Go to starred messages"
macro index,pager gd "<change-folder>=[Gmail]/Drafts<enter>" "Go to drafts"
macro index,pager e "<enter-command>unset trash\n <delete-message>" "Gmail archive message" # different from Gmail, but wanted to keep "y" to show folders.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment