Re: [PATCH] emacs: Add notmuch-show-local-dates option

Subject: Re: [PATCH] emacs: Add notmuch-show-local-dates option

Date: Thu, 02 Jul 2020 15:38:56 -0400

To: Kevin J. Foley, notmuch@notmuchmail.org

Cc:

From: Daniel Kahn Gillmor


This proposed notmuch-show-local-dates feature is a nice one.  It
renders the Date header in a format that is likely to be more useful to
the viewer.  I certainly find this more useful than having to do the
TZ conversions in my head.

But, setting this to t hides the sender's TZ from the viewer -- and i
often find it useful to learn the sender's TZ from the Date: header.

What would be really useful for me is to see the Date header represented
both ways: in my local time *and* the Date header that the sender sent.
But a boolean setting doesn't give me much room to express that
preference.

On Thu 2020-06-25 09:30:16 -0400, Kevin J. Foley wrote:
> Allows users to specify they'd like dates to be displayed in local time

This comment says "time", but the emacs config variable name says
"dates".  This confusion is worse because the Date: header actually
contains a timestamp, not a date ☹

Perhaps we should rename the variable notmuch-show-date-header-localtime,
and it could take three values:

 - nil (default), shows the Date: header as received
 - t, shows the timestamp from the Date: header in local time, 
   with the as-received header in parens afterward (see below)
 - "only", shows only the timestamp in localtime

so if your system is TZ=UTC, and notmuch-show-date-header-localtime is
set to t, and you're looking at a message sent from TZ=America/New_York,
you might see:

Date: Thu, 02 Jul 2020 19:34:53 +0000 (Thu, 02 Jul 2020 15:34:53 -0400)

Would that be too much configurability?

   --dkg
signature.asc (application/pgp-signature)
_______________________________________________
notmuch mailing list -- notmuch@notmuchmail.org
To unsubscribe send an email to notmuch-leave@notmuchmail.org

Thread: