mutt: try to implement multi-accounting

This commit is contained in:
Franzi 2021-04-03 14:43:24 +02:00
parent 414fbf6348
commit cf2935c6e0
Signed by: kunsi
GPG key ID: 12E3D2136B818350
2 changed files with 35 additions and 19 deletions

24
.mutt/ACCOUNT_TEMPLATE Normal file
View file

@ -0,0 +1,24 @@
unmailboxes *
set realname="Franziska"
set imap_user="USERNAME"
set imap_pass="PASSWORD"
set from=""
set spoolfile="+INBOX"
set record="+Sent"
set postponed="+Drafts"
set trash="+Trash"
set folder="imaps://USERNAME@mx0.kunbox.net/"
set smtp_url="smtp://USERNAME:PASSWORD@mx0.kunbox.net:587/"
set pgp_sign_as=GPG_ID
set pgp_autosign=yes
set pgp_encrypt_only_command="pgpewrap gpg --batch --quiet --no-verbose --output - --encrypt --textmode --armor --always-trust--encrypt-to GPG_ID -- -r %r -- %f"
set pgp_encrypt_sign_command="pgpewrap gpg --passphrase-fd 0 --batch --quiet --no-verbose --textmode --output - --encrypt --sign %?a?-u %a? --armor --always-trust --encrypt-to GPG_ID -- -r %r -- %f"
account-hook $folder "set imap_user=USERNAME imap_pass=PASSWORD"
# vim: syntax=muttrc

28
.muttrc
View file

@ -1,17 +1,4 @@
source ~/.mutt/passwords
set realname="Franziska Kunsmann"
set folder="imap://mx0.kunbox.net/"
set spoolfile="+INBOX"
set record="+Sent"
set postponed="+Drafts"
set trash="+Trash"
set from=hi@kunsmann.eu
set use_from=yes set use_from=yes
set smtp_url=smtp://$imap_user:$imap_pass@mx0.kunbox.net:587/
set send_charset=utf-8 set send_charset=utf-8
set edit_headers=yes set edit_headers=yes
@ -54,9 +41,7 @@ set editor="vim -c 'set spell spelllang=de,en'"
source ~/.mutt/gpg.rc source ~/.mutt/gpg.rc
set pgp_use_gpg_agent=yes set pgp_use_gpg_agent=yes
set pgp_sign_as=5FE37FF3C981A9146C3805324205EF53ECE0D2BC
set pgp_timeout=60 set pgp_timeout=60
set pgp_autosign=yes
set crypt_autosign=yes set crypt_autosign=yes
set crypt_replyencrypt=yes set crypt_replyencrypt=yes
set crypt_verify_sig=yes set crypt_verify_sig=yes
@ -67,8 +52,6 @@ set pgp_verify_command="gpg --status-fd=2 --no-verbose --batch --output - --veri
set pgp_decrypt_command="gpg --status-fd=2 --passphrase-fd 0 --no-verbose --batch --output - %f" set pgp_decrypt_command="gpg --status-fd=2 --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_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_clearsign_command="gpg --no-verbose --batch --output - --passphrase-fd 0 --armor --textmode --clearsign %?a?-u %a? %f"
set pgp_encrypt_only_command="pgpewrap gpg --batch --quiet --no-verbose --output - --encrypt --textmode --armor --always-trust --encrypt-to 5FE37FF3C981A9146C3805324205EF53ECE0D2BC -- -r %r -- %f"
set pgp_encrypt_sign_command="pgpewrap gpg --passphrase-fd 0 --batch --quiet --no-verbose --textmode --output - --encrypt --sign %?a?-u %a? --armor --always-trust --encrypt-to 5FE37FF3C981A9146C3805324205EF53ECE0D2BC -- -r %r -- %f"
set pgp_import_command="gpg --no-verbose --import -v %f" set pgp_import_command="gpg --no-verbose --import -v %f"
set pgp_export_command="gpg --no-verbose --export --armor %r" 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_verify_key_command="gpg --no-verbose --batch --fingerprint --check-sigs %r"
@ -83,7 +66,16 @@ bind editor <Tab> complete-query
bind editor ^T complete bind editor ^T complete
bind index,pager S sidebar-toggle-visible bind index,pager S sidebar-toggle-visible
#source ~/.mutt/dracula-theme/dracula.muttrc
source ~/.mutt/spacekookie.theme source ~/.mutt/spacekookie.theme
# Account management
source ~/.mutt/hi@kunsmann.eu
#source ~/.mutt/hostmaster@kunbox.net
#source ~/.mutt/foundyourshit@franzi.business
macro index,pager <f2> '<sync-mailbox><enter-command>source ~/.mutt/hi@kunsmann.eu<enter><change-folder>!<enter>'
macro index,pager <f3> '<sync-mailbox><enter-command>source ~/.mutt/hostmaster@kunbox.net<enter><change-folder>!<enter>'
macro index,pager <f4> '<sync-mailbox><enter-command>source ~/.mutt/foundyourshit@franzi.business<enter><change-folder>!<enter>'
macro index 'c' '<change-folder>?<change-dir><home>^K='
# vim: syntax=muttrc # vim: syntax=muttrc