From: martin f. krafft Date: Mon, 13 Sep 2021 00:05:20 +0000 (+1200) Subject: move mutt config to ~/.config X-Git-Url: https://git.madduck.net/etc/mutt.git/commitdiff_plain/7013dfe93a05082153f79eca6c9e5c05b54d9d50 move mutt config to ~/.config --- diff --git a/.mutt/.gitignore b/.config/mutt/.gitignore similarity index 100% rename from .mutt/.gitignore rename to .config/mutt/.gitignore diff --git a/.mutt/ack-recipients b/.config/mutt/ack-recipients similarity index 97% rename from .mutt/ack-recipients rename to .config/mutt/ack-recipients index b7b1389..8334a45 100644 --- a/.mutt/ack-recipients +++ b/.config/mutt/ack-recipients @@ -1,4 +1,4 @@ -# ~/.mutt/ack-recipients +# ~/.config/mutt/ack-recipients # # This file stores sha256sums of lower-cased e-mail addresses (no newline) # instead of the addresses themselves as a measure to protect privacy. You can diff --git a/.mutt/alternates b/.config/mutt/alternates similarity index 100% rename from .mutt/alternates rename to .config/mutt/alternates diff --git a/.mutt/append-header b/.config/mutt/append-header similarity index 100% rename from .mutt/append-header rename to .config/mutt/append-header diff --git a/.mutt/batch-subject-editor b/.config/mutt/batch-subject-editor similarity index 100% rename from .mutt/batch-subject-editor rename to .config/mutt/batch-subject-editor diff --git a/.mutt/bgrun b/.config/mutt/bgrun similarity index 100% rename from .mutt/bgrun rename to .config/mutt/bgrun diff --git a/.mutt/bgview b/.config/mutt/bgview similarity index 100% rename from .mutt/bgview rename to .config/mutt/bgview diff --git a/.mutt/bgview-delay b/.config/mutt/bgview-delay similarity index 100% rename from .mutt/bgview-delay rename to .config/mutt/bgview-delay diff --git a/.mutt/bgview-fifo b/.config/mutt/bgview-fifo similarity index 100% rename from .mutt/bgview-fifo rename to .config/mutt/bgview-fifo diff --git a/.mutt/colours b/.config/mutt/colours similarity index 100% rename from .mutt/colours rename to .config/mutt/colours diff --git a/.mutt/confvars b/.config/mutt/confvars similarity index 100% rename from .mutt/confvars rename to .config/mutt/confvars diff --git a/.mutt/container-extractor b/.config/mutt/container-extractor similarity index 100% rename from .mutt/container-extractor rename to .config/mutt/container-extractor diff --git a/.mutt/edit-header b/.config/mutt/edit-header similarity index 100% rename from .mutt/edit-header rename to .config/mutt/edit-header diff --git a/.mutt/filter-proxy b/.config/mutt/filter-proxy similarity index 100% rename from .mutt/filter-proxy rename to .config/mutt/filter-proxy diff --git a/.mutt/get-timestamp b/.config/mutt/get-timestamp similarity index 100% rename from .mutt/get-timestamp rename to .config/mutt/get-timestamp diff --git a/.mutt/headers b/.config/mutt/headers similarity index 100% rename from .mutt/headers rename to .config/mutt/headers diff --git a/.mutt/hooks b/.config/mutt/hooks similarity index 100% rename from .mutt/hooks rename to .config/mutt/hooks diff --git a/.mutt/htmldump b/.config/mutt/htmldump similarity index 100% rename from .mutt/htmldump rename to .config/mutt/htmldump diff --git a/.mutt/icalparser b/.config/mutt/icalparser similarity index 100% rename from .mutt/icalparser rename to .config/mutt/icalparser diff --git a/.mutt/keybindings b/.config/mutt/keybindings similarity index 86% rename from .mutt/keybindings rename to .config/mutt/keybindings index 109fff6..9a50eca 100644 --- a/.mutt/keybindings +++ b/.config/mutt/keybindings @@ -67,17 +67,17 @@ macro index,pager e " set my_editor=\$editor set my_editor=\$editor source $my_confdir/batch-subject-editor| set editor=\$my_editor" "change message subject" -macro index,pager \er " set my_editor=\$editor set editor=\"~/.mutt/reuse-message \$my_editor\" set editor=\$my_editor" "invoke normal editor to edit message" -macro index,pager \eg " set my_editor=\$editor set editor=\"~/.mutt/reuse-message \$my_editor\" set editor=\$my_editor" "invoke normal editor to edit message" -macro index,pager \el " set my_editor=\$editor set editor=\"~/.mutt/reuse-message \$my_editor\" set editor=\$my_editor" "invoke normal editor to edit message" +macro index,pager \er " set my_editor=\$editor set editor=\"$my_confdir/reuse-message \$my_editor\" set editor=\$my_editor" "invoke normal editor to edit message" +macro index,pager \eg " set my_editor=\$editor set editor=\"$my_confdir/reuse-message \$my_editor\" set editor=\$my_editor" "invoke normal editor to edit message" +macro index,pager \el " set my_editor=\$editor set editor=\"$my_confdir/reuse-message \$my_editor\" set editor=\$my_editor" "invoke normal editor to edit message" # override F6 from notmuch-mutt macro index "" "do nothing" -macro attach e " set my_mailcap_path=\$mailcap_path set mailcap_path=~/.mutt/mailcap.editing set mailcap_path=\$my_mailcap_path" "edit temporary file of attachment" +macro attach e " set my_mailcap_path=\$mailcap_path set mailcap_path=$my_confdir/mailcap.editing set mailcap_path=\$my_mailcap_path" "edit temporary file of attachment" macro index,pager M " set my_weed=\$weed set noweedformail -czx X-RSS-URL: | xargs sensible-browser set weed=\$my_weed" -macro index,pager " set my_pipe_decode=\$pipe_decode unset pipe_decode~/.mutt/viewmailattachments set pipe_decode=\$my_pipe_decode" "view attachments in browser" +macro index,pager " set my_pipe_decode=\$pipe_decode unset pipe_decode$my_confdir/viewmailattachments set pipe_decode=\$my_pipe_decode" "view attachments in browser" # vim:sw=12:noet:sts=12:ts=12:ft=muttrc diff --git a/.mutt/list-mailboxes b/.config/mutt/list-mailboxes similarity index 100% rename from .mutt/list-mailboxes rename to .config/mutt/list-mailboxes diff --git a/.mutt/lists b/.config/mutt/lists similarity index 100% rename from .mutt/lists rename to .config/mutt/lists diff --git a/.config/mutt/mailcap.backgrounding b/.config/mutt/mailcap.backgrounding new file mode 100644 index 0000000..4dc3516 --- /dev/null +++ b/.config/mutt/mailcap.backgrounding @@ -0,0 +1,8 @@ +# +# Mutt mailcap for backgrounding + +text/html; ~/.config/mutt/bgview-delay -t %t; description=Backgrounded run of run-mailcap with delayed cleanup +application/*; ~/.config/mutt/bgview -t %t; description=Backgrounded run of run-mailcap +image/*; ~/.config/mutt/bgview -t %t; description=Backgrounded run of run-mailcap +audio/*; ~/.config/mutt/bgview -t %t; description=Backgrounded run of run-mailcap +#multipart/related; ~/.config/mutt/viewmailattachments; description=Backgrounded loading of HTML message with related parts diff --git a/.config/mutt/mailcap.containers b/.config/mutt/mailcap.containers new file mode 100644 index 0000000..a53b092 --- /dev/null +++ b/.config/mutt/mailcap.containers @@ -0,0 +1,7 @@ +# +# Mutt mailcap for dumping HTML to text +# + +application/ms-tnef; ~/.config/mutt/container-extractor '%t'; description=Microsoft NIH TNEF +application/x-zip-compressed; ~/.config/mutt/container-extractor '%t'; description=Compressed ZIP files +application/zip; ~/.config/mutt/container-extractor '%t'; description=Compressed ZIP files diff --git a/.config/mutt/mailcap.editing b/.config/mutt/mailcap.editing new file mode 100644 index 0000000..4935e63 --- /dev/null +++ b/.config/mutt/mailcap.editing @@ -0,0 +1,3 @@ +application/pdf; ~/.config/mutt/bgview -t %t -v 'pdftool --file' +application/*; ~/.config/mutt/bgview -t %t +image/*; ~/.config/mutt/bgview -t %t diff --git a/.config/mutt/mailcap.htmldump b/.config/mutt/mailcap.htmldump new file mode 100644 index 0000000..c0b95f5 --- /dev/null +++ b/.config/mutt/mailcap.htmldump @@ -0,0 +1,5 @@ +# +# Mutt mailcap for dumping HTML to text +# + +text/html; ~/.config/mutt/htmldump --from %{charset}; description=HTML Text; nametemplate=%s.html; copiousoutput diff --git a/.config/mutt/mailcap.icalendar b/.config/mutt/mailcap.icalendar new file mode 100644 index 0000000..2c13a19 --- /dev/null +++ b/.config/mutt/mailcap.icalendar @@ -0,0 +1,7 @@ +# +# Mutt mailcap for iCalendar previewing/khal import + +text/calendar; ~/.config/mutt/icalparser; description=iCal details; copiousoutput; \ + print=khal import '%s' +application/ics; ~/.config/mutt/icalparser; description=iCal details; copiousoutput; \ + print=khal import '%s' diff --git a/.mutt/markdown2html b/.config/mutt/markdown2html similarity index 98% rename from .mutt/markdown2html rename to .config/mutt/markdown2html index 487d3db..309c22e 100755 --- a/.mutt/markdown2html +++ b/.config/mutt/markdown2html @@ -14,7 +14,7 @@ # set send_multipart_alternative=yes # set send_multipart_alternative_filter=/path/to/markdown2html.py # -# Optionally, Custom CSS styles will be read from `~/.mutt/markdown2html.css`, +# Optionally, Custom CSS styles will be read from `~/.config/mutt/markdown2html.css`, # if present. # # Requirements: @@ -98,7 +98,7 @@ p { padding: 0 0.5em; } pre { padding: 0 1em; } ''' -STYLESHEET = os.path.join(os.path.expanduser('~/.mutt'), +STYLESHEET = os.path.join(os.path.expanduser('~/.config/mutt'), 'markdown2html.css') if os.path.exists(STYLESHEET): DEFAULT_CSS += open(STYLESHEET).read() diff --git a/.mutt/mkconf b/.config/mutt/mkconf similarity index 100% rename from .mutt/mkconf rename to .config/mutt/mkconf diff --git a/.mutt/multipart-alternative b/.config/mutt/multipart-alternative similarity index 100% rename from .mutt/multipart-alternative rename to .config/mutt/multipart-alternative diff --git a/.mutt/muttrc b/.config/mutt/muttrc similarity index 97% rename from .mutt/muttrc rename to .config/mutt/muttrc index 84f4311..2eb88ff 100644 --- a/.mutt/muttrc +++ b/.config/mutt/muttrc @@ -1,6 +1,6 @@ # from /usr/share/doc/mutt/examples/Muttrc.gz -set my_confdir="$HOME/.mutt" +set my_confdir="$HOME/.config/mutt" set my_attribution_de="Hinsichtlich folgendem, das \"%n\" am %{%Y-%m-%d} um %{%H:%M Uhr %Z} schrieb:" set my_attribution_en="Regarding the following, written by \"%n\" on %{%Y-%m-%d} at %{%H:%M Uhr %Z}:" diff --git a/.mutt/remove-header b/.config/mutt/remove-header similarity index 100% rename from .mutt/remove-header rename to .config/mutt/remove-header diff --git a/.mutt/replace-header b/.config/mutt/replace-header similarity index 100% rename from .mutt/replace-header rename to .config/mutt/replace-header diff --git a/.mutt/reuse-message b/.config/mutt/reuse-message similarity index 100% rename from .mutt/reuse-message rename to .config/mutt/reuse-message diff --git a/.mutt/sendmail b/.config/mutt/sendmail similarity index 75% rename from .mutt/sendmail rename to .config/mutt/sendmail index 80fd4a1..a6ff7c9 100755 --- a/.mutt/sendmail +++ b/.config/mutt/sendmail @@ -3,16 +3,16 @@ # mutt/sendmail – sendmail wrapper to enforce some checks on outgoing mails # # The script basically just creates a temporary file and then invokes any -# executable scripts in ~/.mutt/sendmail-checks.d in run-parts style. They -# receive the filename of a temporary file holding the message to be sent as -# $1, followed by all recipients as determined by mutt. +# executable scripts in ~/.config/mutt/sendmail-checks.d in run-parts style. +# They receive the filename of a temporary file holding the message to be sent +# as $1, followed by all recipients as determined by mutt. # -# Copyright © 2010 martin f. krafft -# Released under the terms of the Artistic Licence 2.0 +# Copyright © 2010 martin f. krafft Released under the +# terms of the Artistic Licence 2.0 # set -eux -CHECKSDIR="$HOME/.mutt/sendmail-checks.d" +CHECKSDIR="$HOME/.config/mutt/sendmail-checks.d" SENDMAIL="/usr/sbin/sendmail -oem -oi" TMPFILE=$(mktemp --tmpdir mutt-sendmail.XXXXXXXXXX.msg) diff --git a/.mutt/sendmail-checks.d/ack-recipients b/.config/mutt/sendmail-checks.d/ack-recipients similarity index 73% rename from .mutt/sendmail-checks.d/ack-recipients rename to .config/mutt/sendmail-checks.d/ack-recipients index 749b1d6..9a052ad 100755 --- a/.mutt/sendmail-checks.d/ack-recipients +++ b/.config/mutt/sendmail-checks.d/ack-recipients @@ -2,13 +2,14 @@ # # ack-recipients – require double-checking of some recipients # -# refuse to send a mail as long as recipients listed in ~/.mutt/ack-recipients -# are not individually "signed-off" by adding their e-mail addresses to the -# X-Acked header. This header is removed from the mail before it is sent. +# refuse to send a mail as long as recipients listed in +# ~/.config/mutt/ack-recipients are not individually "signed-off" by adding +# their e-mail addresses to the X-Acked header. This header is removed from +# the mail before it is sent. # -# The file ~/.mutt/ack-recipients stores sha256sums of lower-cased e-mail -# addresses (no newline) instead of the addresses themselves as a measure to -# protect privacy. You can get new lines like this: +# The file ~/.config/mutt/ack-recipients stores sha256sums of lower-cased +# e-mail addresses (no newline) instead of the addresses themselves as a +# measure to protect privacy. You can get new lines like this: # # printf my.new@e-mail.addre.ss | tr '[[:upper:]]' '[[:lower:]]' \ # | sha256sum | sed -e 's, .*,,' @@ -21,7 +22,7 @@ # set -eu -CHECKLIST="$HOME/.mutt/ack-recipients" +CHECKLIST="$HOME/.config/mutt/ack-recipients" HEADER=X-Acked ACKED_RCPTS=$(formail -czx ${HEADER}: < $1 | tr -d ',' | tr '[[:upper:]]' '[[:lower:]]') MAILFILE="$1"; shift diff --git a/.mutt/sendmail-checks.d/check-attachments b/.config/mutt/sendmail-checks.d/check-attachments similarity index 100% rename from .mutt/sendmail-checks.d/check-attachments rename to .config/mutt/sendmail-checks.d/check-attachments diff --git a/.mutt/sendmail-checks.d/no-local-recipients b/.config/mutt/sendmail-checks.d/no-local-recipients similarity index 100% rename from .mutt/sendmail-checks.d/no-local-recipients rename to .config/mutt/sendmail-checks.d/no-local-recipients diff --git a/.mutt/sendmail-checks.d/pgp-mime-sig-description b/.config/mutt/sendmail-checks.d/pgp-mime-sig-description similarity index 100% rename from .mutt/sendmail-checks.d/pgp-mime-sig-description rename to .config/mutt/sendmail-checks.d/pgp-mime-sig-description diff --git a/.mutt/sendmail-checks.d/prevent-draft b/.config/mutt/sendmail-checks.d/prevent-draft similarity index 100% rename from .mutt/sendmail-checks.d/prevent-draft rename to .config/mutt/sendmail-checks.d/prevent-draft diff --git a/.mutt/sendmail-checks.d/strip-offlineimap-header b/.config/mutt/sendmail-checks.d/strip-offlineimap-header similarity index 100% rename from .mutt/sendmail-checks.d/strip-offlineimap-header rename to .config/mutt/sendmail-checks.d/strip-offlineimap-header diff --git a/.mutt/sendmail-checks.d/strip-tickle-header b/.config/mutt/sendmail-checks.d/strip-tickle-header similarity index 100% rename from .mutt/sendmail-checks.d/strip-tickle-header rename to .config/mutt/sendmail-checks.d/strip-tickle-header diff --git a/.mutt/sendmail-checks.d/zzz_add-spool-bcc b/.config/mutt/sendmail-checks.d/zzz_add-spool-bcc similarity index 100% rename from .mutt/sendmail-checks.d/zzz_add-spool-bcc rename to .config/mutt/sendmail-checks.d/zzz_add-spool-bcc diff --git a/.mutt/sidebar b/.config/mutt/sidebar similarity index 100% rename from .mutt/sidebar rename to .config/mutt/sidebar diff --git a/.mutt/spam b/.config/mutt/spam similarity index 100% rename from .mutt/spam rename to .config/mutt/spam diff --git a/.mutt/supersede-header b/.config/mutt/supersede-header similarity index 100% rename from .mutt/supersede-header rename to .config/mutt/supersede-header diff --git a/.mutt/viewmailattachments b/.config/mutt/viewmailattachments similarity index 100% rename from .mutt/viewmailattachments rename to .config/mutt/viewmailattachments diff --git a/.gitignore.d/mutt b/.gitignore.d/mutt index 719883b..56d44f1 100644 --- a/.gitignore.d/mutt +++ b/.gitignore.d/mutt @@ -1,54 +1,53 @@ * +!/.config/mutt/ack-recipients +!/.config/mutt/alternates +!/.config/mutt/append-header +!/.config/mutt/batch-subject-editor +!/.config/mutt/bgrun +!/.config/mutt/bgview +!/.config/mutt/bgview-delay +!/.config/mutt/bgview-fifo +!/.config/mutt/colours +!/.config/mutt/confvars +!/.config/mutt/container-extractor +!/.config/mutt/edit-header +!/.config/mutt/filter-proxy +!/.config/mutt/get-timestamp +!/.config/mutt/.gitignore +!/.config/mutt/headers +!/.config/mutt/hooks +!/.config/mutt/htmldump +!/.config/mutt/icalparser +!/.config/mutt/keybindings +!/.config/mutt/list-mailboxes +!/.config/mutt/lists +!/.config/mutt/mailcap.backgrounding +!/.config/mutt/mailcap.containers +!/.config/mutt/mailcap.editing +!/.config/mutt/mailcap.htmldump +!/.config/mutt/mailcap.icalendar +!/.config/mutt/markdown2html +!/.config/mutt/mkconf +!/.config/mutt/multipart-alternative +!/.config/mutt/muttrc +!/.config/mutt/remove-header +!/.config/mutt/replace-header +!/.config/mutt/reuse-message +!/.config/mutt/sendmail +!/.config/mutt/sendmail-checks.d/ack-recipients +!/.config/mutt/sendmail-checks.d/check-attachments +!/.config/mutt/sendmail-checks.d/no-local-recipients +!/.config/mutt/sendmail-checks.d/pgp-mime-sig-description +!/.config/mutt/sendmail-checks.d/prevent-draft +!/.config/mutt/sendmail-checks.d/strip-offlineimap-header +!/.config/mutt/sendmail-checks.d/strip-tickle-header +!/.config/mutt/sendmail-checks.d/zzz_add-spool-bcc +!/.config/mutt/sidebar +!/.config/mutt/spam +!/.config/mutt/supersede-header +!/.config/mutt/viewmailattachments !/.crontab.d/mutt !/.gitignore.d/mutt -!/.mutt -!/.mutt/ack-recipients -!/.mutt/alternates -!/.mutt/append-header -!/.mutt/batch-subject-editor -!/.mutt/bgrun -!/.mutt/bgview -!/.mutt/bgview-delay -!/.mutt/bgview-fifo -!/.mutt/colours -!/.mutt/confvars -!/.mutt/container-extractor -!/.mutt/edit-header -!/.mutt/filter-proxy -!/.mutt/get-timestamp -!/.mutt/.gitignore -!/.mutt/headers -!/.mutt/hooks -!/.mutt/htmldump -!/.mutt/icalparser -!/.mutt/keybindings -!/.mutt/list-mailboxes -!/.mutt/lists -!/.mutt/mailcap.backgrounding -!/.mutt/mailcap.containers -!/.mutt/mailcap.editing -!/.mutt/mailcap.htmldump -!/.mutt/mailcap.icalendar -!/.mutt/markdown2html -!/.mutt/mkconf -!/.mutt/multipart-alternative -!/.mutt/muttrc !/.muttprintrc -!/.mutt/remove-header -!/.mutt/replace-header -!/.mutt/reuse-message -!/.mutt/sendmail -!/.mutt/sendmail-checks.d/ack-recipients -!/.mutt/sendmail-checks.d/check-attachments -!/.mutt/sendmail-checks.d/no-local-recipients -!/.mutt/sendmail-checks.d/pgp-mime-sig-description -!/.mutt/sendmail-checks.d/prevent-draft -!/.mutt/sendmail-checks.d/strip-offlineimap-header -!/.mutt/sendmail-checks.d/strip-tickle-header -!/.mutt/sendmail-checks.d/zzz_add-spool-bcc -!/.mutt/sidebar -!/.mutt/spam -!/.mutt/supersede-header -!/.mutt/viewmailattachments !/.var/mutt/.gitignore !/.var/mutt/header_cache/.gitignore diff --git a/.mutt/mailcap.backgrounding b/.mutt/mailcap.backgrounding deleted file mode 100644 index b47a8bc..0000000 --- a/.mutt/mailcap.backgrounding +++ /dev/null @@ -1,8 +0,0 @@ -# -# Mutt mailcap for backgrounding - -text/html; ~/.mutt/bgview-delay -t %t; description=Backgrounded run of run-mailcap with delayed cleanup -application/*; ~/.mutt/bgview -t %t; description=Backgrounded run of run-mailcap -image/*; ~/.mutt/bgview -t %t; description=Backgrounded run of run-mailcap -audio/*; ~/.mutt/bgview -t %t; description=Backgrounded run of run-mailcap -#multipart/related; ~/.mutt/viewmailattachments; description=Backgrounded loading of HTML message with related parts diff --git a/.mutt/mailcap.containers b/.mutt/mailcap.containers deleted file mode 100644 index 3006186..0000000 --- a/.mutt/mailcap.containers +++ /dev/null @@ -1,7 +0,0 @@ -# -# Mutt mailcap for dumping HTML to text -# - -application/ms-tnef; ~/.mutt/container-extractor '%t'; description=Microsoft NIH TNEF -application/x-zip-compressed; ~/.mutt/container-extractor '%t'; description=Compressed ZIP files -application/zip; ~/.mutt/container-extractor '%t'; description=Compressed ZIP files diff --git a/.mutt/mailcap.editing b/.mutt/mailcap.editing deleted file mode 100644 index f2e48d5..0000000 --- a/.mutt/mailcap.editing +++ /dev/null @@ -1,3 +0,0 @@ -application/pdf; ~/.mutt/bgview -t %t -v 'pdftool --file' -application/*; ~/.mutt/bgview -t %t -image/*; ~/.mutt/bgview -t %t diff --git a/.mutt/mailcap.htmldump b/.mutt/mailcap.htmldump deleted file mode 100644 index 6a3743d..0000000 --- a/.mutt/mailcap.htmldump +++ /dev/null @@ -1,5 +0,0 @@ -# -# Mutt mailcap for dumping HTML to text -# - -text/html; ~/.mutt/htmldump --from %{charset}; description=HTML Text; nametemplate=%s.html; copiousoutput diff --git a/.mutt/mailcap.icalendar b/.mutt/mailcap.icalendar deleted file mode 100644 index 79dcecf..0000000 --- a/.mutt/mailcap.icalendar +++ /dev/null @@ -1,7 +0,0 @@ -# -# Mutt mailcap for iCalendar previewing/khal import - -text/calendar; ~/.mutt/icalparser; description=iCal details; copiousoutput; \ - print=khal import '%s' -application/ics; ~/.mutt/icalparser; description=iCal details; copiousoutput; \ - print=khal import '%s'