From: Simon Ruderich Date: Sat, 2 Jun 2018 11:45:42 +0000 (+0200) Subject: Merge branch 'mail' X-Git-Url: https://ruderich.org/simon/gitweb/?p=config%2Fdotfiles.git;a=commitdiff_plain;h=6ca1d9bd09d69a729b389694866006c985eba3e0;hp=c0ae7152026890b30acaa87498e3950b2ad1164e Merge branch 'mail' --- diff --git a/mail/.gitignore b/mail/.gitignore new file mode 100644 index 0000000..2a54f18 --- /dev/null +++ b/mail/.gitignore @@ -0,0 +1,15 @@ +# Ignore GnuPG files not stored in Git. +/gnupg/pubring.gpg +/gnupg/pubring.gpg~ +/gnupg/random_seed +/gnupg/secring.gpg +/gnupg/trustdb.gpg + +# Ignore files generated by setup.sh. +/mutt/display + +# Ignore local files. +/mutt/adfooters/ +/mutt/mlfooters/ +# Ignore generated files. +/mutt/history diff --git a/mail/Makefile b/mail/Makefile new file mode 100644 index 0000000..23d5991 --- /dev/null +++ b/mail/Makefile @@ -0,0 +1,4 @@ +all: + @./setup.sh + +.PHONY: all diff --git a/mail/abook/abookrc b/mail/abook/abookrc new file mode 100644 index 0000000..d7b40ce --- /dev/null +++ b/mail/abook/abookrc @@ -0,0 +1,38 @@ +# Configuration file for abook, a curses based address book. +# +# Works only with abook >= 0.6.0pre2! + +# Copyright (C) 2009-2012 Simon Ruderich +# +# This file is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This file is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this file. If not, see . + + +# Preserve all fields in ~/.abook/addressbook even if not defined by field. +# This makes sure no data is lost when working with a different field +# configuration. +set preserve_fields = all + +# My custom fields. +field birthday = Birthday, date +field im = Instant-Messenger, list +field urls = URLs, list # additional URLs + +# Display only important (to me) fields. +view CONTACT = name, email, im, url, urls +view ADDRESS = address, zip, city, country +view PHONE = phone, workphone, fax, mobile +view OTHER = birthday, nick, notes + +# Use elinks as browser. +set www_command=elinks diff --git a/mail/gnupg/gpg.conf b/mail/gnupg/gpg.conf new file mode 100644 index 0000000..2cbec14 --- /dev/null +++ b/mail/gnupg/gpg.conf @@ -0,0 +1,82 @@ +# Configuration file for GnuPG. +# +# Thanks to [1] for some hints to generate stronger keys (read on 2013-04-04). +# +# [1]: https://we.riseup.net/riseuplabs+paow/openpgp-best-practices + +# Copyright (C) 2009-2013 Simon Ruderich +# +# This file is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This file is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this file. If not, see . + + +# DISPLAY + +# Don't display the copyright notice. +no-greeting + +# Use long keyids because the short ones have collisions. +keyid-format 0xlong + + +# KEY GENERATION + +# Use stronger preferences. These are not enforced, but tried in the given +# order and the first supported by all recipients is used. +# +# Ciphers for encryption. +personal-cipher-preferences AES256 AES192 AES CAST5 +# Don't use insecure hashes like SHA1 or MD5 and prefer stronger hashes. +personal-digest-preferences SHA512 SHA384 SHA256 SHA224 +# Prefer better compression methods. +personal-compress-preferences BZIP2 ZLIB ZIP Uncompressed + +# Default preferences when generating a new key. Use the three settings above +# combined to create stronger keys. +default-preference-list SHA512 SHA384 SHA256 SHA224 AES256 AES192 AES CAST5 BZIP2 ZLIB ZIP Uncompressed + +# Don't use SHA1 when signing keys, this includes self-certificates. This +# setting is separate from the settings above and needs to be explicitly set +# or SHA1 will be used! Thanks to [1]. +cert-digest-algo SHA512 + + +# KEY PROTECTION + +# Mangle passphrases for private keys and symmetric encryption by applying a +# hash function (s2k-digest-algo) with a salt s2k-count times (default). +s2k-mode 3 +# Increase count. Takes ~0.5 seconds on my machine. +s2k-count 3538944 +# Use SHA-512 as hash function. Takes a little longer than SHA-1, which is the +# default. +s2k-digest-algo SHA512 + + +# KEYSERVERS + +# Use the given keyserver. +keyserver hkp://pool.sks-keyservers.net + +# Don't use the preferred keyserver of the key, but our keyserver pool +# instead. This way we won't use any broken keyservers like pgp.mit.edu +# specified by the key. +keyserver-options no-honor-keyserver-url + + +# MY KEYS + +# Use my newest key as default key. +default-key 0x92FEFDB7E44C32F9 + +# vim: ft=gpg diff --git a/mail/lbdbrc b/mail/lbdbrc new file mode 100644 index 0000000..c30f296 --- /dev/null +++ b/mail/lbdbrc @@ -0,0 +1,20 @@ +# Configuration file for little brothers database lbdb. + +# Copyright (C) 2009-2012 Simon Ruderich +# +# This file is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This file is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this file. If not, see . + + +# Use abook and gpg as sources. +METHODS="m_abook m_gpg" diff --git a/mail/mailcap b/mail/mailcap new file mode 100644 index 0000000..50d184b --- /dev/null +++ b/mail/mailcap @@ -0,0 +1,20 @@ +# Mailcap file used by mutt to decode html messages. + +# Copyright (C) 2007-2012 Simon Ruderich +# +# This file is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This file is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this file. If not, see . + + +# Allows mutt to decode text/html attachments and display them inline. +text/html; lynx -dump -assume_charset=%{charset} -display_charset=utf-8 %s; copiousoutput; nametemplate=%s.html diff --git a/mail/mutt/adfooters/.gitignore b/mail/mutt/adfooters/.gitignore new file mode 100644 index 0000000..e69de29 diff --git a/mail/mutt/crypto b/mail/mutt/crypto new file mode 100644 index 0000000..c5b08bc --- /dev/null +++ b/mail/mutt/crypto @@ -0,0 +1,58 @@ +# muttrc file for gpg support + +# Copyright (C) 2007-2012 Simon Ruderich +# +# This file is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This file is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this file. If not, see . + + +# settings for gpg to decrypt/encrypt/verify: +set pgp_decode_command="gpg %?p?--passphrase-fd 0? --no-verbose --batch --output - %f" +set pgp_verify_command="gpg --no-verbose --batch --output - --verify %s %f" +set pgp_decrypt_command="gpg --passphrase-fd 0 --no-verbose --batch --output - %f" +set pgp_sign_command="gpg --no-verbose --batch --output - --passphrase-fd 0 --armor --detach-sign --textmode %?a?-u %a? %f" +set pgp_clearsign_command="gpg --no-verbose --batch --output - --passphrase-fd 0 --armor --textmode --clearsign %?a?-u %a? %f" +set pgp_encrypt_only_command="/usr/lib/mutt/pgpewrap gpg --batch --quiet --no-verbose --output - --encrypt --textmode --armor --always-trust --encrypt-to %a -- -r %r -- %f" +set pgp_encrypt_sign_command="/usr/lib/mutt/pgpewrap gpg --passphrase-fd 0 --batch --quiet --no-verbose --textmode --output - --encrypt --sign %?a?-u %a? --armor --always-trust --encrypt-to %a -- -r %r -- %f" +set pgp_import_command="gpg --no-verbose --import --verbose %f" +set pgp_export_command="gpg --no-verbose --export --armor %r" +set pgp_verify_key_command="gpg --no-verbose --batch --fingerprint --check-sigs %r" +set pgp_list_pubring_command="gpg --no-verbose --batch --with-colons --list-keys %r" +set pgp_list_secring_command="gpg --no-verbose --batch --with-colons --list-secret-keys %r" +# match necessary for a good signature: +set pgp_good_sign="^gpg: Good signature from" + +# use inline signatures for compatibility with other clients and mailing +# lists: +set pgp_create_traditional=yes + +# automatically sign every mail: +set pgp_autosign=yes +# automatically encrypt replies on encrypted mails: +set pgp_replyencrypt=yes + +# automatically verify inline signatures: +set pgp_auto_decode=yes + +# store the gpg password for half an hour: +set pgp_timeout=1800 + +# use my key for signing/encrypting: +set pgp_sign_as=0x92FEFDB7E44C32F9 + +# enable encryption for all known GnuPG keys. crypto-autoencrypt.pl creates +# all the necessary hooks: +send-hook . 'set crypt_autoencrypt=no' +source ~/.mutt/crypto-autoencrypt.pl| + +# vim: ft=muttrc diff --git a/mail/mutt/crypto-autoencrypt.pl b/mail/mutt/crypto-autoencrypt.pl new file mode 100755 index 0000000..08cf146 --- /dev/null +++ b/mail/mutt/crypto-autoencrypt.pl @@ -0,0 +1,38 @@ +#!/usr/bin/perl + +# Helper script for mutt to create a list of send-hooks which enable +# crypt_autoencrypt for known GnuPG keys. + +# Copyright (C) 2009-2013 Simon Ruderich +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + + +use strict; +use warnings; + +open my $gpg, '-|', 'gpg --list-keys --with-colons --fixed-list-mode' or die $!; +while (<$gpg>) { + next if not /^uid:/; + + # We don't skip invalid, deleted, revoked, expired and not-trusted UIDs to + # prevent sending an unencrypted mail when e.g. a key is revoked or + # expired; GnuPG will warn if we use any of them. If you really want to + # skip those UIDs (not recommended), uncomment the next line. + #next if /^uid:[idren]:/; + + next if not /<(.+?@.+?)>:/; + print "send-hook '~t $1' 'set crypt_autoencrypt=yes'\n"; +} +close $gpg or die $!; diff --git a/mail/mutt/display.in b/mail/mutt/display.in new file mode 100644 index 0000000..22688b7 --- /dev/null +++ b/mail/mutt/display.in @@ -0,0 +1,172 @@ +# muttrc file for the mail display + +# Copyright (C) 2007-2013 Simon Ruderich +# +# This file is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This file is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this file. If not, see . + + +# Don't display help bar at the top of the screen. +set help=no + +# don't display sidebar, enabled by setup.sh if the sidebar patch is used: +#set sidebar_visible=no + +# automatically display html mails as plain text: +auto_view text/html +# but ensure plain mail is used if it exists: +alternative_order text/plain + +# assume iso-8859-1 for unspecified charsets in emails as it's the most used, +# not a perfect solution, but it works most of the time well: +set assumed_charset=iso-8859-1 + + +# sort threads with new messages in old threads like new threads: +set sort_aux=last-date-received + +# mark missing messages in threads with a '?' in the thread display: +set hide_missing=no +set hide_top_missing=no + + +# use a wider index format (35 instead of 15 characters): +# also display the number of attachments: +set index_format="%4C %Z %{%b %d} %-35.35L (%?l?%4l&%4c?)%?X?(%X)& ? %s" + +# display a small email index while reading email contents: +set pager_index_lines=5 + +# when scrolling mails repeat the three last lines on the next screen: +set pager_context=3 + + +# only update the read/write counter every 2000 mails, this increases speed: +set read_inc=2000 +set write_inc=2000 + + +# wrap email content to 78 characters, this increases readability (for me): +set wrap=78 +# don't display any '+' markers when a line is wrapped: +set markers=no +# display ~s at the end of each message so it's clear where the message ends: +set tilde + +# order the headers in mail display by this order: +hdr_order Date: From: To: Cc: Bcc: Subject: + + +# ignore settings +# +# I ignore only certain headers so I can see custom headers; the first ignore +# rule in each section ignores standard, the second non standard headers +# +# thanks to [1] for a very helpful list of mail headers +# [1]: http://people.dsv.su.se/~jpalme/ietf/mail-headers/mail-headers.html + +# reset all ignores so I can see all headers I don't ignore in the following +# rules: +unignore * + +# ignore mbox from header: +ignore "from " + +# ignore trace information headers: +ignore received return-path + +# ignore format and control information headers: +ignore content-disposition mime-version + +# ignore sender and recipient indication headers: +ignore sender +ignore apparently-to x-face x-sender envelope-to + +# ignore response control headers: +ignore reply-to +ignore errors-to followup-to mail-followup-to + +# ignore message identification headers: +ignore in-reply-to references +ignore delivered-to + +# ignore headers containing dates and times: +ignore delivery-date + +# ignore quality information headers: +ignore precedence + +# ignore size information headers: +#ignore +ignore content-length lines + +# ignore encoding information headers: +ignore content-transfer-encoding content-type encoding + +# ignore mailing list control headers: +ignore list-archive list-help list-id list-post list-subscribe \ + list-unsubscribe + +# ignore miscellaneous headers (non standard): +ignore status x-status # mail status, used by mail clients + + +# color settings +# +# thanks to http://www.therandymon.com/woodnotes/mutt/node46.html for the +# settings to allow transparency (default) +# +# thanks to Debian Lenny mutt default files for the color settings + +# normal text: +color normal white default +# mail headers: +color hdrdefault cyan default +# attachments: +color attachment brightyellow default +# marker for the currently selected mail in the index: +color indicator default cyan +# signature (if correctly delimited with "-- "): +color signature cyan default +# status bar (at top and bottom): +color status brightgreen blue +# tildes at the bottom if there is no more content: +color tilde blue default +# thread tree markers: +color tree red default + +# mark quotes: +color quoted magenta default +color quoted1 cyan default +# mark the writer of the quote the same color as the quote: +color body magenta default ".+ <.+> writes:" +color body magenta default "On .+ wrote:" +color body cyan default "> .+ <.+> writes:" +color body cyan default "> On .+ wrote:" + +# mark subject: +color header brightgreen default ^Subject: + +# mark important messages red: +color index white red "~F" + +# mark valid gpg signatures: +color body green default "gpg: Good signature from .+" +# mark invalid gpg signatures: +color body red default "gpg: BAD signature from .+" +# mark encrypted mails: +color body green default "gpg: encrypted with .+" +# mark missing gpg public keys: +color body yellow default "gpg: Can't check signature: public key not found" + +# vim: ft=muttrc diff --git a/mail/mutt/handling b/mail/mutt/handling new file mode 100644 index 0000000..f82f113 --- /dev/null +++ b/mail/mutt/handling @@ -0,0 +1,29 @@ +# muttrc file for mail handling; stores macros and commands + +# Copyright (C) 2007-2012 Simon Ruderich +# +# This file is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This file is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this file. If not, see . + + +# allow the use of in attachment menu to open them: +bind attach view-attach +# allow the use of 'i' to quit the attachment menu: +bind attach i exit + +# when opening the inbox or mailinglists display at first only flagged emails: +# f toggles between flagged/all mails +folder-hook "^(inbox$|lists/)" source ~/.mutt/handling-flagged +#folder-hook . source ~/.mutt/handling-unflagged # FIXME: this doesn't work + +# vim: ft=muttrc diff --git a/mail/mutt/handling-flagged b/mail/mutt/handling-flagged new file mode 100644 index 0000000..d1f4ecd --- /dev/null +++ b/mail/mutt/handling-flagged @@ -0,0 +1,27 @@ +# muttrc file to toggle between flagged an unflagged mails +# when sourced display only flagged emails, next call to f toggles + +# Copyright (C) 2007-2012 Simon Ruderich +# +# This file is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This file is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this file. If not, see . + + +# display only flagged mails: +# un/set beep prevents warnings if there are no flagged messages +push "unset beep~Fset beep" + +# macro to display all mails: +macro index f "source ~/.mutt/handling-unflagged" + +# vim: ft=muttrc diff --git a/mail/mutt/handling-unflagged b/mail/mutt/handling-unflagged new file mode 100644 index 0000000..0a76453 --- /dev/null +++ b/mail/mutt/handling-unflagged @@ -0,0 +1,27 @@ +# muttrc file to toggle between flagged an unflagged mails +# when sourced display all emails, next call to f toggles + +# Copyright (C) 2007-2012 Simon Ruderich +# +# This file is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This file is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this file. If not, see . + + +# display all mails, also go to the next new/unread message: +# un/set beep prevents warnings with next-new-then-unread if there are no unread messages +push ".unset beepset beep" + +# macro to display only flagged mails: +macro index f "source ~/.mutt/handling-flagged" + +# vim: ft=muttrc diff --git a/mail/mutt/load b/mail/mutt/load new file mode 100644 index 0000000..84f0b6d --- /dev/null +++ b/mail/mutt/load @@ -0,0 +1,37 @@ +# muttrc file which loads all rc files + +# Copyright (C) 2007-2012 Simon Ruderich +# +# This file is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This file is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this file. If not, see . + + +# load mail/mailbox settings: +source ~/.mutt/mails + +# load sending settings: +source ~/.mutt/send + +# load macros and commands settings: +source ~/.mutt/handling + +# load display settings: +source ~/.mutt/display + +# load gpg support: +source ~/.mutt/crypto + +# load t-prot support: +source ~/.mutt/t-prot + +# vim: ft=muttrc diff --git a/mail/mutt/mails b/mail/mutt/mails new file mode 100644 index 0000000..22a111c --- /dev/null +++ b/mail/mutt/mails @@ -0,0 +1,54 @@ +# muttrc file for mailbox and email settings + +# Copyright (C) 2007-2012 Simon Ruderich +# +# This file is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This file is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this file. If not, see . + + +# use my inbox as mbox: +set mbox=+inbox-gray + +# store send emails in this mailbox: +set record=+send/outbox +# store postponed mails in this file: +set postponed=+postponed + + +# use the little brother database to get information about emails (no quotes +# around %s!): +set query_command="lbdbq %s" + + +# automatically append emails to other mailboxes: +set confirmappend=no +# automatically delete emails when changing/closing a mailbox: +set delete=yes +# don't ask to move read mails from spool file to mbox: +set move=no + +# automatically quote the message when replying: +set include=yes +# allow editing of headers when sending a mail: +set edit_headers=yes +# make sure autoedit is disabled as it causes problems with several hooks +# (send-hook, reply-hook, crypt-hook, etc.) +set autoedit=no + +# don't mark old new mails as "O", mark them as "N": +set mark_old=no + +# ask before quitting: +set quit=ask-yes + +# vim: ft=muttrc diff --git a/mail/mutt/mlfooters/.gitignore b/mail/mutt/mlfooters/.gitignore new file mode 100644 index 0000000..e69de29 diff --git a/mail/mutt/muttrc b/mail/mutt/muttrc new file mode 100644 index 0000000..fffcbc3 --- /dev/null +++ b/mail/mutt/muttrc @@ -0,0 +1,22 @@ +# muttrc configuration file + +# Copyright (C) 2007-2012 Simon Ruderich +# +# This file is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This file is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this file. If not, see . + + +# use account ruderich.com for mutt: +source ~/.mutt/ruderich + +# vim: ft=muttrc diff --git a/mail/mutt/ruderich b/mail/mutt/ruderich new file mode 100644 index 0000000..38c07f9 --- /dev/null +++ b/mail/mutt/ruderich @@ -0,0 +1,62 @@ +# muttrc file for account ruderich.org/ruderich.com + +# Copyright (C) 2007-2012 Simon Ruderich +# +# This file is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This file is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this file. If not, see . + + +# set my identity: +set from=simon@ruderich.org +set realname="Simon Ruderich" +# use this as hostname so the local hostname is not used: +set hostname=ruderich.org + +# set my additional mail addresses: +alternates simon@ruderich.org simon@ruderich.com + + +# use my signature, language dependent: +send-hook . 'set signature=~/.mutt/ruderich-signature' +send-hook '~t\.de$' 'set signature=~/.mutt/ruderich-signature-de' + + +# use ~/mail as my folder: +set folder=~/mail + +# my inboxes so they are checked for new mail: +mailboxes `echo $HOME/mail/inbox*` +# my mailing lists so they are checked for new mail: +mailboxes `echo $HOME/mail/lists/*` + + +# automatically sort after threads in mailing lists: +folder-hook . set sort=date +folder-hook lists set sort=threads +folder-hook programming set sort=threads + +# allow threads in privoxy-requsts: +folder-hook . set sort_re=yes +folder-hook lists/archive/privoxy-requests set sort_re=no + +# allow reading gzip compressed mailboxes: +open-hook \\.gz$ "gzip -cd %f > %t" + + +# load muttrc files: +source ~/.mutt/load + +# Display mutt's version on startup. +push + +# vim: ft=muttrc diff --git a/mail/mutt/ruderich-signature b/mail/mutt/ruderich-signature new file mode 100644 index 0000000..bc63428 --- /dev/null +++ b/mail/mutt/ruderich-signature @@ -0,0 +1,3 @@ ++ privacy is necessary ++ using gnupg http://gnupg.org ++ public key id: 0x92FEFDB7E44C32F9 diff --git a/mail/mutt/ruderich-signature-de b/mail/mutt/ruderich-signature-de new file mode 100644 index 0000000..167b746 --- /dev/null +++ b/mail/mutt/ruderich-signature-de @@ -0,0 +1,3 @@ ++ Privatsphäre ist notwendig ++ Ich verwende GnuPG http://gnupg.org ++ Öffentlicher Schlüssel: 0x92FEFDB7E44C32F9 diff --git a/mail/mutt/send b/mail/mutt/send new file mode 100644 index 0000000..a1cdeed --- /dev/null +++ b/mail/mutt/send @@ -0,0 +1,25 @@ +# muttrc file for sending mails + +# Copyright (C) 2007-2012 Simon Ruderich +# +# This file is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This file is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this file. If not, see . + + +# use vim as editor for sending mails: +set editor=vim + +# use msmtp as MDA: +set sendmail=msmtp + +# vim: ft=muttrc diff --git a/mail/mutt/t-prot b/mail/mutt/t-prot new file mode 100644 index 0000000..d3f4f46 --- /dev/null +++ b/mail/mutt/t-prot @@ -0,0 +1,25 @@ +# $Id: muttrc.t-prot,v 1.9 2002/12/29 03:52:57 jochen Exp $ + +# CHANGES by Simon Ruderich: +# - use my helper script 'mutt-display-filter' +# - work on transparent terminals (default color setting) + + +# This all works only if you have mutt-1.3.12 or newer +# or if you use something like the pagerfilter patch +# (http://www.escape.de/users/tolot/mutt/). +set display_filter='mutt-display-filter' + +# toggle TOFU protection with ESC-0 and ESC-1 +macro generic \e0 ":unset display_filter\n" "Turn TOFU protection off" +macro generic \e1 ":set display_filter='mutt-display-filter'\n" "Turn TOFU protection on" + +# same in pager mode - ugly but what the hell... +macro pager \e0 ":unset display_filter; exec exit\n:exec display-message\n" "Turn TOFU protection off" +macro pager \e1 ":set display_filter='mutt-display-filter'; exec exit\n:exec display-message\n" "Turn TOFU protection on" + +# highlight TOFU protection: +color body brightmagenta default "^\\[---.*" +color body green default "^#v[-+]" + +# vim: ft=muttrc diff --git a/mail/setup.sh b/mail/setup.sh new file mode 100755 index 0000000..2d6e9b2 --- /dev/null +++ b/mail/setup.sh @@ -0,0 +1,41 @@ +#!/bin/sh + +# Setup script for mail configuration files. + +# Copyright (C) 2009-2013 Simon Ruderich +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + + +set -eu + +. ../lib.sh + + +generate mutt/display .in cat +if mutt -v | grep sidebar >/dev/null 2>&1; then + echo 'mutt/display: enabling mutt sidebar settings' + sed_i 's/^#set sidebar_/set sidebar_/' mutt/display +fi + +# Link setup. +if installed abook; then + link abook ~/.abook +fi +link gnupg ~/.gnupg +if installed lbdb; then + link lbdbrc ~/.lbdbrc +fi +link mailcap ~/.mailcap +link mutt ~/.mutt