diff options
| -rw-r--r-- | .mutt/muttrc | 64 | ||||
| -rw-r--r-- | .mutt/muttrc.aliases | 3 | ||||
| -rw-r--r-- | .mutt/muttrc.binds | 13 | ||||
| -rw-r--r-- | .mutt/muttrc.colors | 60 | ||||
| -rw-r--r-- | .mutt/muttrc.hooks | 5 | ||||
| -rwxr-xr-x | .mutt/muttrc.hooks.env | 5 | ||||
| -rw-r--r-- | .mutt/muttrc.macros | 52 | ||||
| -rwxr-xr-x | .mutt/muttrc.macros.env | 5 | ||||
| -rwxr-xr-x | .mutt/muttrc.mailboxes.env | 7 | ||||
| -rwxr-xr-x | .mutt/muttrc.send.env | 10 | ||||
| -rw-r--r-- | .mutt/muttrc.sidebar | 6 | ||||
| -rw-r--r-- | .mutt/muttrc.theme.dracula | 42 | ||||
| -rw-r--r-- | .mutt/muttrc.theme.gruvbox-shuber | 81 | 
13 files changed, 353 insertions, 0 deletions
| diff --git a/.mutt/muttrc b/.mutt/muttrc new file mode 100644 index 0000000..a8a0245 --- /dev/null +++ b/.mutt/muttrc @@ -0,0 +1,64 @@ +# The basics +set folder="~/mail" +set header_cache = "~/.cache/mutt/headers" +set mbox_type=Maildir +set message_cachedir = "~/.cache/mutt/messages" +set postponed="=drafts" +set record="sent" +set sort="threads" +set forward_format = "Fwd: %s" # Format of subject when forwarding + +# Tweaks +unset help               # Remove annoying messages +set beep_new +set charset="utf-8" +set fast_reply +set fast_reply=yes       # Skip prompt for subject and recipients when replying +set hidden_host=yes +set include              # Include message in replies +set mailcap_path = $HOME/.mailcap +set mark_old=no +set markers=no +set mask="!^\\.[^.]" +set pager_context=5      # Retain 5 lines of previous page when scrolling. +set send_charset="utf-8" +set sleep_time = 0 +set smart_wrap           # Do not wrap mid word +set wait_key=no + +# Pager +set pager_index_lines = 10 # Number of index lines to show +set pager_context = 3      # Number of context lines to show +set pager_stop             # Don't go to next message automatically + +# PGP +set pgp_auto_decode=yes +set pgp_getkeys_command="gpg --recv-keys %r 2>/dev/null" + +# Sanitize messages with t-prot +set display_filter='t-prot -cmekatlS --max-lines=250 --bigq --pgp-short --pgp-move --pgp-move-vrf -Mmutt -L/etc/t-prot/footers -A/etc/t-prot/ads' + +# Date format +set date_format="!%a, %b %d, %Y at %I:%M:%S%p %Z" + +# Conditional time +set index_format='%4C %Z %<[y?%<[m?%<[d?%[%H:%M ]&%[%a %d]>&%[%b %d]>&%[%m/%y ]> %-15.15L (%?l?%4l&%4c?) %s' + +# Status Bar +set status_chars  = " *%A" +set status_format = "───[ Folder: %f ]───[%r%m messages%?n? (%n new)?%?d? (%d to delete)?%?t? (%t tagged)? ]───%>─%?p?( %p postponed )?───" + +# HTML +auto_view text/html image/*  application/x-gunzip application/x-tar-gz +alternative_order text/plain text/enriched text/html + +# Extra configs +source "$HOME/.mutt/muttrc.aliases" +source "$HOME/.mutt/muttrc.binds" +source "$HOME/.mutt/muttrc.colors" +source "$HOME/.mutt/muttrc.hooks" +source "$HOME/.mutt/muttrc.macros" +source "$HOME/.mutt/muttrc.sidebar" + +source "$HOME/.mutt/muttrc.mailboxes.env|" +source "$HOME/.mutt/muttrc.send.env|" diff --git a/.mutt/muttrc.aliases b/.mutt/muttrc.aliases new file mode 100644 index 0000000..0b0bcaf --- /dev/null +++ b/.mutt/muttrc.aliases @@ -0,0 +1,3 @@ +set alias_file="$HOME/.mutt/muttrc.aliases" + +# Add your aliases here diff --git a/.mutt/muttrc.binds b/.mutt/muttrc.binds new file mode 100644 index 0000000..a595874 --- /dev/null +++ b/.mutt/muttrc.binds @@ -0,0 +1,13 @@ +# mutt sidebar settings +bind index,pager \CP sidebar-prev +bind index,pager \CN sidebar-next +bind index,pager \CO sidebar-open + +bind index,pager p previous-entry +bind index,pager n next-entry + +bind pager i exit +bind pager z create-alias + +bind index <Esc><Tab> next-unread-mailbox +bind pager <Esc><Tab> next-unread-mailbox diff --git a/.mutt/muttrc.colors b/.mutt/muttrc.colors new file mode 100644 index 0000000..c463740 --- /dev/null +++ b/.mutt/muttrc.colors @@ -0,0 +1,60 @@ +## Diffs +color body green default "^diff \-.*" +color body green default "^index [a-f0-9].*" +color body green default "^\-\-\- .*" +color body green default "^[\+]{3} .*" +color body cyan default "^[\+][^\+]+.*" +color body red  default "^\-[^\-]+.*" +color body brightblue default "^@@ .*" + +# Various smilies and the like +color body          brightwhite     default         "<[Gg]>"                            # <g> +color body          brightwhite     default         "<[Bb][Gg]>"                        # <bg> +color body          yellow          default         " [;:]-*[})>{(<|]"                  # :-) etc... + +# *bold* +color body          brightyellow            default         "(^|[[:space:][:punct:]])\\*[^*]+\\*([[:space:][:punct:]]|$)" +mono  body          bold                            "(^|[[:space:][:punct:]])\\*[^*]+\\*([[:space:][:punct:]]|$)" + +# _underline_ +color body          brightred            default         "(^|[[:space:]])" + +color sidebar_new color221 default + +# index stuff +color tree color244 default +color indicator color255 color233 +color index color117 color233 ~N +color index color124 color233 ~D + +# URLs, email and web +color body color68 color233 "(finger|ftp|http|https|news|telnet)://[^ >]*" +color body color111 color233 "<URL:[^ ]*>" +color body color111 color233 "www\\.[-.a-z0-9]+\\.[a-z][a-z][a-z]?([-_./~a-z0-9]+)?" +color body color111 default "[-a-z_0-9.%$]+@[-a-z_0-9.]+\\.[-a-z][-a-z]+" +color body brightred color233 "^-.*" +color body green color233 "^[+].*" +color body brightwhite color233 "^diff .*" +color body brightyellow color233 "^@@.*" + +# Misc body +color attachment color111 default +color signature color244 default + +# GPG +color body       color188 default "^gpg: Good signature.*" +color body       color115 color236 "^gpg: BAD signature.*" +color body       color174 color237 "^gpg: Can't check signature.*" +color body       color174 color237 "^-----BEGIN PGP SIGNED MESSAGE-----" +color body       color174 color237 "^-----BEGIN PGP SIGNATURE-----" +color body       color174 color237 "^-----END PGP SIGNED MESSAGE-----" +color body       color174 color237 "^-----END PGP SIGNATURE-----" +color body       color174 color237 "^Version: GnuPG.*" +color body       color174 color237 "^Comment: .*" + +# Highlight TOFU protection: +color body	brightmagenta		default	"^\\[---.*" +color body	green			default	"^#v[-+]" + +# Include theme +source "$HOME/.mutt/muttrc.theme.dracula" diff --git a/.mutt/muttrc.hooks b/.mutt/muttrc.hooks new file mode 100644 index 0000000..e0add57 --- /dev/null +++ b/.mutt/muttrc.hooks @@ -0,0 +1,5 @@ +## Folder hooks +folder-hook .  'set record="^"' +folder-hook .  push "<delete-pattern>~=<enter>$" + +source "$HOME/.mutt/muttrc.hooks.env|" diff --git a/.mutt/muttrc.hooks.env b/.mutt/muttrc.hooks.env new file mode 100755 index 0000000..cb412b8 --- /dev/null +++ b/.mutt/muttrc.hooks.env @@ -0,0 +1,5 @@ +#!/bin/bash + +# Add more hooks here +cat << ENDOFMUTTRC +ENDOFMUTTRC diff --git a/.mutt/muttrc.macros b/.mutt/muttrc.macros new file mode 100644 index 0000000..2dc8eba --- /dev/null +++ b/.mutt/muttrc.macros @@ -0,0 +1,52 @@ +# Common macros +macro index \eR "|~/bin/mutt-remember-mail\n" +macro pager \cu <pipe-entry>'urlview'<enter> 'Follow links with urlview' + +macro index,pager \cb "<pipe-message> urlscan<Enter>" "call urlscan to extract URLs out of a message" +macro attach,compose \cb "<pipe-entry> urlscan<Enter>" "call urlscan to extract URLs out of a message" + +# Sidebar +macro index,pager B '<enter-command>toggle sidebar_visible<enter>' + +macro index <right> "<enter-command>toggle sidebar_visible<enter><display-message>" +macro pager <left> "<enter-command>toggle sidebar_visible<enter><exit>" + +macro index,pager D "<delete-message><sync-mailbox><enter>" "Delete message" + +macro index <F6> \ +"<enter-command>unset wait_key<enter><pipe-message>notmuch new<enter>" \ +"notmuch: Index new messages" + + +macro index <F7> \ +        "<enter-command>unset wait_key<enter><shell-escape>~/bin/mutt-fetchbug --prompt search<enter><change-folder-readonly>~/.cache/mutt_btsresults<enter><enter-command>set wait_key<enter>" \ +        "fetch bug(s) (using bts show)" + +macro index <F8> \ +"<enter-command>set my_old_pipe_decode=\$pipe_decode my_old_wait_key=\$wait_key nopipe_decode nowait_key<enter>\ +<shell-escape>notmuch-mutt -r --prompt search<enter>\ +<change-folder-readonly>`echo ${XDG_CACHE_HOME:-$HOME/.cache}/notmuch/mutt/results`<enter>\ +<enter-command>set pipe_decode=\$my_old_pipe_decode wait_key=\$my_old_wait_key<enter>" \ +      "notmuch: search mail" + +macro index <F9> \ +"<enter-command>set my_old_pipe_decode=\$pipe_decode my_old_wait_key=\$wait_key nopipe_decode nowait_key<enter>\ +<pipe-message>notmuch-mutt -r thread<enter>\ +<change-folder-readonly>`echo ${XDG_CACHE_HOME:-$HOME/.cache}/notmuch/mutt/results`<enter>\ +<enter-command>set pipe_decode=\$my_old_pipe_decode wait_key=\$my_old_wait_key<enter>" \ +      "notmuch: reconstruct thread" + +macro index <esc>m "T~N<enter>;WN^T~T<enter>T~O<enter>;WN^T~T<enter>" "mark all messages read" + + +# toggle TOFU protection with ESC-0 (off) and ESC-1 (on) +macro generic \e0 ":unset display_filter\n" "Turn TOFU protection off" +macro generic \e1 ":set display_filter='t-prot -cmekatlS --max-lines=250 --bigq --pgp-short --pgp-move --pgp-move-vrf -Mmutt -L/etc/t-prot/footers -A/etc/t-prot/ads'\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='t-prot -cmekatlS --max-lines=250 --bigq --pgp-short --pgp-move --pgp-move-vrf -Mmutt -L/etc/t-prot/footers -A/etc/t-prot/ads'; exec exit\n:exec display-message\n" "Turn TOFU protection on" + +macro attach 'V' "<pipe-entry>cat > ~/tmp/mail.html && xdg-open ~/tmp/mail.html && rm -f ~/tmp/mail.html<enter>" + +source "$HOME/.mutt/muttrc.macros.env|"
\ No newline at end of file diff --git a/.mutt/muttrc.macros.env b/.mutt/muttrc.macros.env new file mode 100755 index 0000000..790c65d --- /dev/null +++ b/.mutt/muttrc.macros.env @@ -0,0 +1,5 @@ +#!/bin/bash + +# Add more macros here +cat << ENDOFMUTTRC +ENDOFMUTTRC diff --git a/.mutt/muttrc.mailboxes.env b/.mutt/muttrc.mailboxes.env new file mode 100755 index 0000000..8542be3 --- /dev/null +++ b/.mutt/muttrc.mailboxes.env @@ -0,0 +1,7 @@ +#!/bin/bash + +# Add your mailboxes here +cat << ENDOFMUTTRC +# set spoolfile="=/INBOX" +# mailboxes "=/INBOX" +ENDOFMUTTRC diff --git a/.mutt/muttrc.send.env b/.mutt/muttrc.send.env new file mode 100755 index 0000000..1e2e488 --- /dev/null +++ b/.mutt/muttrc.send.env @@ -0,0 +1,10 @@ +#!/bin/bash + +# Add your sendmail conf here +cat << ENDOFMUTTRC +# set realname='Mr. Example' +# set from="example@example.com" + +# set sendmail="/usr/bin/msmtp --read-envelope-from" +# set pgp_sign_as="" +ENDOFMUTTRC diff --git a/.mutt/muttrc.sidebar b/.mutt/muttrc.sidebar new file mode 100644 index 0000000..a680443 --- /dev/null +++ b/.mutt/muttrc.sidebar @@ -0,0 +1,6 @@ +set mail_check_stats=yes +set sidebar_visible=yes +set sidebar_format="%B%*  %S%?N?(%N)?%?F?[%F]?" +set sidebar_indent_string=" " +set sidebar_folder_indent=yes +set sidebar_short_path=yes diff --git a/.mutt/muttrc.theme.dracula b/.mutt/muttrc.theme.dracula new file mode 100644 index 0000000..f94fd1a --- /dev/null +++ b/.mutt/muttrc.theme.dracula @@ -0,0 +1,42 @@ +############################################################################### +# Dracula Theme for Mutt: https://draculatheme.com/ +# +# @author Paul Townsend <paul@caprica.org> + +# general ------------ foreground ---- background ----------------------------- +color error		color231	color212 +color indicator		color231	color241 +color markers		color210	default +color message		default		default +color normal		default		default +color prompt		default	        default +color search		color84		default +color status 		color141	color236 +color tilde		color231	default +color tree		color141	default + +# message index ------ foreground ---- background ----------------------------- +color index		color210	default 	~D # deleted messages +color index		color84		default 	~F # flagged messages +color index		color117	default 	~N # new messages +color index		color212	default 	~Q # messages which have been replied to +color index		color215	default 	~T # tagged messages +color index		color141	default		~v # messages part of a collapsed thread + +# message headers ---- foreground ---- background ----------------------------- +color hdrdefault	color117	default +color header		color231	default		^Subject:.* + +# message body ------- foreground ---- background ----------------------------- +color attachment	color228	default +color body		color231	default		[\-\.+_a-zA-Z0-9]+@[\-\.a-zA-Z0-9]+               # email addresses +color body		color228	default		(https?|ftp)://[\-\.,/%~_:?&=\#a-zA-Z0-9]+        # URLs +color body		color231	default		(^|[[:space:]])\\*[^[:space:]]+\\*([[:space:]]|$) # *bold* text +color body		color231	default		(^|[[:space:]])_[^[:space:]]+_([[:space:]]|$)     # _underlined_ text +color body		color231	default		(^|[[:space:]])/[^[:space:]]+/([[:space:]]|$)     # /italic/ text +color quoted		color61		default +color quoted1		color117	default +color quoted2		color84		default +color quoted3		color215	default +color quoted4		color212	default +color signature		color212	default
\ No newline at end of file diff --git a/.mutt/muttrc.theme.gruvbox-shuber b/.mutt/muttrc.theme.gruvbox-shuber new file mode 100644 index 0000000..0b958af --- /dev/null +++ b/.mutt/muttrc.theme.gruvbox-shuber @@ -0,0 +1,81 @@ +# gruvbox dark (contrast dark): + +# bg0    = 234 +# bg1    = 237 +# bg2    = 239 +# bg3    = 241 +# bg4    = 243 +#  +# gray   = 245 +#  +# fg0    = 229 +# fg1    = 223 +# fg2    = 250 +# fg3    = 248 +# fg4    = 246 +#  +# red    = 167 +# green  = 142 +# yellow = 214 +# blue   = 109 +# purple = 175 +# aqua   = 108 +# orange = 208 + + +# See http://www.mutt.org/doc/manual/#color + +color attachment  color109 color234 +color bold        color229 color234 +color error       color167 color234 +color hdrdefault  color246 color234 +color indicator   color223 color237 +color markers     color243 color234 +color normal      color223 color234 +color quoted      color250 color234 +color quoted1     color108 color234 +color quoted2     color250 color234 +color quoted3     color108 color234 +color quoted4     color250 color234 +color quoted5     color108 color234 +color search      color234 color208 +color signature   color108 color234 +color status      color234 color250 +color tilde       color243 color234 +color tree        color142 color234 +color underline   color223 color239 + +color sidebar_divider    color250 color234 +color sidebar_new        color142 color234 + +color index color142 color234 ~N +color index color108 color234 ~O +color index color109 color234 ~P +color index color214 color234 ~F +color index color175 color234 ~Q +color index color167 color234 ~= +color index color234 color223 ~T +color index color234 color167 ~D + +color header color214 color234 "^(To:|From:)" +color header color142 color234 "^Subject:" +color header color108 color234 "^X-Spam-Status:" +color header color108 color234 "^Received:" + +color body color142 color234 "[a-z]{3,256}://[-a-zA-Z0-9@:%._\\+~#=/?&,]+" +#color body color142 color234 "[a-zA-Z]([-a-zA-Z0-9_]+\\.){2,256}[-a-zA-Z0-9_]{2,256}" +color body color208 color234 "[-a-z_0-9.%$]+@[-a-z_0-9.]+\\.[-a-z][-a-z]+" +color body color208 color234 "mailto:[-a-z_0-9.]+@[-a-z_0-9.]+" +color body color234 color214 "[;:]-*[)>(<lt;|]" +color body color229 color234 "\\*[- A-Za-z]+\\*" + +color body color214 color234 "^-.*PGP.*-*" +color body color142 color234 "^gpg: Good signature from" +color body color167 color234 "^gpg: Can't.*$" +color body color214 color234 "^gpg: WARNING:.*$" +color body color167 color234 "^gpg: BAD signature from" +color body color167 color234 "^gpg: Note: This key has expired!" +color body color214 color234 "^gpg: There is no indication that the signature belongs to the owner." +color body color214 color234 "^gpg: can't handle these multiple signatures" +color body color214 color234 "^gpg: signature verification suppressed" +color body color214 color234 "^gpg: invalid node with packet of type" | 
