From e5916afc8dec89d402c35a179aea485f8835303a Mon Sep 17 00:00:00 2001 From: Florian Fischer Date: Fri, 17 Jul 2020 14:14:56 +0200 Subject: [lumail] sort by date instead of threads and only show new messages by default --- config/lumail/lumail.lua | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/config/lumail/lumail.lua b/config/lumail/lumail.lua index 757fc9c..f176935 100644 --- a/config/lumail/lumail.lua +++ b/config/lumail/lumail.lua @@ -114,6 +114,16 @@ Config:set ( "log.level", "") -- Config:set( "index.format", "[${4|flags}] ${2|message_flags} | ${10|date} | ${20|sender} | ${indent}${subject}" ) + +-- Override Message:to_ctime to use the lua header cache + +do + local old_ctime = Message.ctime + function Message:ctime() + return self.header("Delivery-Date") or self.header("Date") or old_ctime(self) + end +end + -- -- Options include: -- @@ -137,10 +147,17 @@ Config:set( "index.format", -- `subject` - Sort by subject. -- `from` - Sort by sender. -- -sorting_method( "threads" ) +sorting_method( "date" ) +-- sorting_method( "threads" ) Config:set("threads.sort", "date") + +-- +-- Only show unread messages by default +-- +Config:set( "index.limit", "new" ) + -- -- Unread messages/maildirs are drawn in red. -- -- cgit v1.2.3