]> Sergey Matveev's repositories - dotfiles.git/commitdiff
Newer mu and combined back/sent folders
authorSergey Matveev <stargrave@stargrave.org>
Mon, 31 Oct 2022 15:21:08 +0000 (18:21 +0300)
committerSergey Matveev <stargrave@stargrave.org>
Mon, 31 Oct 2022 19:27:31 +0000 (22:27 +0300)
mutt/.mutt/muttrc
mutt/bin/sent [new file with mode: 0755]
zsh/.zsh/rc/010mail.zsh

index 9b53c6ddae84a0a334d6d154a75d1181f8fab956..b7fc9579722b0932c95aeac4fdc6eafd558d7453 100644 (file)
@@ -2,7 +2,7 @@ set folder = "~/mail"
 set mbox_type = maildir
 # set mbox_type = mbox
 set spoolfile = =mbox
-set record = =sent-`date "+%y-%m"`
+set record = =back-`date "+%y-%m"`
 set postponed = =postponed
 set certificate_file = ~/.mutt/certificates
 set net_inc = 1
@@ -40,8 +40,9 @@ macro index,pager,browser <F1> "<next-unread-mailbox><enter>"
 macro index <F5> ":set mbox_type = mbox\n" "mbox mailbox type"
 macro index S "<save-message>=spamdb<enter>"
 
-macro index <F8> "<shell-escape>mu find --clearlinks --format=links --linksdir=~/mail/search " "mu find"
-macro index <F9> "<change-folder-readonly>~/mail/search<enter>" "mu find results"
+macro index <F6> "<shell-escape>mu find --clearlinks --format=links --linksdir=~/mail/search " "mu find"
+macro index <F7> "<change-folder-readonly>~/mail/search<enter>" "mu find results"
+macro index <F8> "<change-folder-readonly>~/mail/search-sent<enter>" "mu find sent results"
 
 macro pager \cu |urlview\n
 
diff --git a/mutt/bin/sent b/mutt/bin/sent
new file mode 100755 (executable)
index 0000000..218097e
--- /dev/null
@@ -0,0 +1,9 @@
+#!/bin/sh -e
+
+alts=$(perl -lane '
+    next unless /^alternates/;
+    push @alts, "f:$F[1]";
+    sub END { print join " or ", @alts };
+' ~/.mutt/accounts/*)
+mfind date:2m.. "($alts)"
+mutt -f =search-sent
index 8c5d9958c1c1907f0bcad5d5b2f26106de99813b..50f8984d01820e94309d0f8de9ea31063ccbb0ac 100644 (file)
@@ -3,5 +3,5 @@ mailpath=(
     ~/mail/arbeit/new"?Neue Nachrichten in =arbeit"
 )
 alias arr="mutt -f =arbeit -e 'source ~/.mutt/accounts/arbeit'"
-alias sent="mutt -f =sent-\`date '+%y-%m'\`"
+export MUHOME=~/.mu
 bindkey -s "\eOP" " inc\n" # F1