Al Haji-Ali <abdo.haji.ali@gmail.com> writes: > Would it be possible to search for lastmod messages based on time > rather than revision ID? Using revision ID is convenient for > tools/scripts, but not for actual everyday use. > The modification time is not saved in the database. > I sometimes find myself needing to find a message that I accidentally > archived/moved and it would be convenient if I can list all the > messages that I modified (tag or otherwise) in the past day for > example. I currently use the current value of revision ID minus a few > hundreds as a proxy for time. A workaround could be to run a cron job or equivalent that logs (lastmod,timestamp) pairs to a file. Of course that would make using the information a bit inconvenient without further tooling. Because of concerns about performance, we have so far resisted having a "tagging hook". 'lastmod:' was added at some point because it addressed some of the usecases for a tagging hook. At the time (2014) we chose the counter approach over timestamps because of the difficulty of synchronizing clocks between machines and the possibility of clock changes on a given machine [1]. In principle modification timestamps could be added as additional data for each message. I'm not sure about the cost/benefit here (either for implementation or performance) but if someone wants to investigate further I can point them in the right direction (mostly, copy the lastmod stuff). [1]: I think most of the discussion is in the thread https://nmbug.notmuchmail.org/nmweb/show/1396800683-9164-1-git-send-email-eg%40gaute.vetsj.com _______________________________________________ notmuch mailing list -- notmuch@notmuchmail.org To unsubscribe send an email to notmuch-leave@notmuchmail.org