add mutt config

auto-flake-update
Yorick van Pelt 2016-09-21 20:06:55 +02:00
parent d6d78fe8c5
commit 92bae59a20
7 changed files with 212 additions and 1 deletions

View File

@ -1,4 +1,4 @@
#!/usr/bin/env nix-shell #!/usr/bin/env nix-shell
#!nix-shell -i bash -p stow #!nix-shell -i bash -p stow
stow -d `dirname $0` -t ~ nix git x pentadactyl i3 gtk gpg stow -d `dirname $0` -t ~ nix git x pentadactyl i3 gtk gpg mutt
nix-build -A $(hostname -s) nix-build -A $(hostname -s)

83
mutt/.mutt/colors Normal file
View File

@ -0,0 +1,83 @@
# -- # {{{1
#
# File : mail/mutt/colours
# Maintainer : Felix C. Stegerman <flx@obfusk.net>
# Date : 2014-08-22
#
# Copyright : Copyright (C) 2014 Felix C. Stegerman
# Licence : GPLv3+
#
# Transparency edit : Yorick van Pelt, 2016
# -- # }}}1
# index, ...
color error brightred default
color indicator black white
color message brightyellow default
color normal default default
color status brightwhite blue
color tree red default
# pager
color attachment brightyellow default
color hdrdefault cyan default
color markers brightred default
color quoted green default
color search black white
color signature blue default
color tilde blue default
# headers
color header white default "^Subject:"
color header brightred default "^From:"
color header brightyellow default "^Date:"
color header brightgreen default "^To:"
color header green default "^Cc:"
# index highlight
# * new mail
# * mail sent my me
color index blue default "~(~P)" # threads posted in
color index green default "~P" # my messages
color index yellow default "~(~N)" # in thread w/ new
color index brightyellow default "~N" # new messages
color index magenta default "~(~F)" # in thread w/ flagged
color index red default "~(~F) ~N" # new in thread w/ flagged
color index brightred default "~F" # flagged messages
color index cyan default "~D" # deleted messages
color index brightwhite default "~T" # tagged messages
# body highlight
# * email addresses
# * http(s), ftp
#
# * bold [nroff]
# * underline [nroff]
#
# * *bold* [disabled]
# * _underline_ [disabled]
# * /italic/ [disabled]
color body brightred default \
"[\-\.+_a-zA-Z0-9]+@[\-\.a-zA-Z0-9]+"
color body brightblue default \
"(https?|ftp)://[\-\.,/%~_:?&=\#a-zA-Z0-9]+"
color bold brightwhite default
color underline brightwhite default
# color body brightwhite default "[*]+[^*]+[*]+"
# color body brightwhite default "_+[^_]+_+"
# color body brightwhite default "/+[^/]+/+"

8
mutt/.mutt/creds Normal file
View File

@ -0,0 +1,8 @@
set my_pass = "`gpg -q --no-tty --batch -d ~/.mutt/yorick_pass.gpg`""
set spoolfile = "imaps://yorick:$my_pass@pennyworth.yori.cc/INBOX"
set realname = "Yorick van Pelt"
set from = "Yorick van Pelt <yorick@yorickvanpelt.nl>"
set folder = "imaps://pennyworth.yori.cc/"
set smtp_url = "smtp://yorick@pennyworth.yori.cc:587/"
set smtp_pass = "$my_pass"

88
mutt/.mutt/gpg Normal file
View File

@ -0,0 +1,88 @@
# -*-muttrc-*-
#
# Command formats for gpg.
#
# This version uses gpg-2comp from
# http://70t.de/download/gpg-2comp.tar.gz
#
# $Id$
#
# %p The empty string when no passphrase is needed,
# the string "PGPPASSFD=0" if one is needed.
#
# This is mostly used in conditional % sequences.
#
# %f Most PGP commands operate on a single file or a file
# containing a message. %f expands to this file's name.
#
# %s When verifying signatures, there is another temporary file
# containing the detached signature. %s expands to this
# file's name.
#
# %a In "signing" contexts, this expands to the value of the
# configuration variable $pgp_sign_as. You probably need to
# use this within a conditional % sequence.
#
# %r In many contexts, mutt passes key IDs to pgp. %r expands to
# a list of key IDs.
# Note that we explicitly set the comment armor header since GnuPG, when used
# in some localiaztion environments, generates 8bit data in that header, thereby
# breaking PGP/MIME.
# decode application/pgp
set pgp_decode_command="gpg --status-fd=2 %?p?--passphrase-fd 0? --no-verbose --quiet --batch --output - %f"
# verify a pgp/mime signature
set pgp_verify_command="gpg --status-fd=2 --no-verbose --quiet --batch --output - --verify %s %f"
# decrypt a pgp/mime attachment
set pgp_decrypt_command="gpg --status-fd=2 %?p?--passphrase-fd 0? --no-verbose --quiet --batch --output - %f"
# create a pgp/mime signed attachment
# set pgp_sign_command="gpg-2comp --comment '' --no-verbose --batch --output - %?p?--passphrase-fd 0? --armor --detach-sign --textmode %?a?-u %a? %f"
set pgp_sign_command="gpg --no-verbose --batch --quiet --output - %?p?--passphrase-fd 0? --armor --detach-sign --textmode %?a?-u %a? %f"
# create a application/pgp signed (old-style) message
# set pgp_clearsign_command="gpg-2comp --comment '' --no-verbose --batch --output - %?p?--passphrase-fd 0? --armor --textmode --clearsign %?a?-u %a? %f"
set pgp_clearsign_command="gpg --no-verbose --batch --quiet --output - %?p?--passphrase-fd 0? --armor --textmode --clearsign %?a?-u %a? %f"
# create a pgp/mime encrypted attachment
# set pgp_encrypt_only_command="pgpewrap gpg-2comp -v --batch --output - --encrypt --textmode --armor --always-trust -- -r %r -- %f"
set pgp_encrypt_only_command="pgpewrap gpg --batch --quiet --no-verbose --output - --encrypt --textmode --armor --always-trust -- -r %r -- %f"
# create a pgp/mime encrypted and signed attachment
# set pgp_encrypt_sign_command="pgpewrap gpg-2comp %?p?--passphrase-fd 0? -v --batch --output - --encrypt --sign %?a?-u %a? --armor --always-trust -- -r %r -- %f"
set pgp_encrypt_sign_command="pgpewrap gpg %?p?--passphrase-fd 0? --batch --quiet --no-verbose --textmode --output - --encrypt --sign %?a?-u %a? --armor --always-trust -- -r %r -- %f"
# import a key into the public key ring
set pgp_import_command="gpg --no-verbose --import %f"
# export a key from the public key ring
set pgp_export_command="gpg --no-verbose --export --armor %r"
# verify a key
set pgp_verify_key_command="gpg --verbose --batch --fingerprint --check-sigs %r"
# read in the public key ring
set pgp_list_pubring_command="gpg --no-verbose --batch --quiet --with-colons --with-fingerprint --with-fingerprint --list-keys %r"
# read in the secret key ring
set pgp_list_secring_command="gpg --no-verbose --batch --quiet --with-colons --with-fingerprint --with-fingerprint --list-secret-keys %r"
# fetch keys
# set pgp_getkeys_command="pkspxycwrap %r"
# pattern for good signature - may need to be adapted to locale!
# set pgp_good_sign="^gpgv?: Good signature from "
# OK, here's a version which uses gnupg's message catalog:
# set pgp_good_sign="`gettext -d gnupg -s 'Good signature from "' | tr -d '"'`"
# This version uses --status-fd messages
set pgp_good_sign="^\\[GNUPG:\\] GOODSIG"
# pattern to verify a decryption occurred
set pgp_decryption_okay="^\\[GNUPG:\\] DECRYPTION_OKAY"

4
mutt/.mutt/mailboxes Normal file
View File

@ -0,0 +1,4 @@
set record="=Sent"
set postponed="=Drafts"
set trash="=Archive"
mailboxes =INBOX =Archive =Sent =Spam =Trash

28
mutt/.mutt/muttrc Normal file
View File

@ -0,0 +1,28 @@
source ~/.mutt/colors
source ~/.mutt/gpg
source ~/.mutt/mailboxes
source ~/.mutt/creds
set edit_headers
set auto_tag
set imap_servernoise
unset imap_passive
set mail_check = 60
set header_cache = ~/.mutt/hcache
set message_cachedir = ~/.mutt/msg_cache
set net_inc = 5
set sort = threads
set sort_browser = date
set sort_aux = reverse-last-date-received
set sidebar_width= 10
set pgp_verify_sig
set pgp_replysign
set pgp_sign_as = DC014A15
ifdef ENCRYPT_SELF set pgp_encrypt_self
set pgp_use_gpg_agent
bind index G imap-fetch-mail

BIN
mutt/.mutt/yorick_pass.gpg Normal file

Binary file not shown.