aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2020-06-29 01:13:08 +1200
committerTom Ryder <tom@sanctum.geek.nz>2020-06-29 01:23:01 +1200
commit64b0e5b218a27b810c8da2f41d086bfc598a230f (patch)
treeac592641ee1d5acd89c40e31bdb7994b8231b939
parentRemove an idea I decided not to implement (diff)
downloaddotfiles-64b0e5b218a27b810c8da2f41d086bfc598a230f.tar.gz
dotfiles-64b0e5b218a27b810c8da2f41d086bfc598a230f.zip
Expand/refine Mutt thread display switching a bit
-rw-r--r--mutt/muttrc14
1 files changed, 11 insertions, 3 deletions
diff --git a/mutt/muttrc b/mutt/muttrc
index ccd88412..e71d676c 100644
--- a/mutt/muttrc
+++ b/mutt/muttrc
@@ -268,12 +268,20 @@ macro generic,index,browser,pager \\R '\
<enter-command>echo "Reloaded $my_muttrc"<enter>' \
"Clear hooks and reload"
-# Shortcut to toggle thread display
+# I often want thread display when having to keep track of multiple
+# conversations at once with multiple people replying to one another, as is
+# regularly the case when reading mailing lists, but for my personal mail it's
+# generally nicer to sort the messages simply by date. This macro uses
+# user-defined variables to toggle $sort between "date" and "threads".
+#
+set sort = date
set my_sort_alt = threads
macro index \\t '\
-<enter-command>set my_sort_cur = $sort<enter>\
+<enter-command>set my_sort_tmp = $sort<enter>\
<enter-command>set sort = $my_sort_alt<enter>\
-<enter-command>set my_sort_alt = $my_sort_cur<enter>' \
+<enter-command>set my_sort_alt = $my_sort_tmp<enter>\
+<enter-command>unset my_sort_tmp<enter>\
+<enter-command>set ?sort<enter>' \
"Toggle thread display"
# Set a few simple colors just for a quick visual cue of which tool I'm looking