cripslock

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README

commit 5700bc59045a8d640f5058bd49d4fa3eb2e434f9
parent 0b0a724f167200b84e3880870000acf60b8ad430
Author: Daniel Barlow <dan@telent.net>
Date:   Tue, 22 Jul 2025 20:35:14 +0100

emacs timestamps may have > 1 space between month and date

Diffstat:
Msite.fnl | 3++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/site.fnl b/site.fnl @@ -38,7 +38,7 @@ (fn parse-emacs-timestamp [date-str] (let [(s _ weekday month day hour min sec year) - (string.find date-str "(%a+) (%a+) (%d+) (%d+):(%d+):(%d+) (%d+)" 1)] + (string.find date-str "(%a+) (%a+) +(%d+) (%d+):(%d+):(%d+) (%d+)" 1)] (and s (os.time { : year @@ -62,6 +62,7 @@ (expect= (parse-emacs-timestamp "Sat Jul 19 23:53:21 2025") 1752965601) (expect= (parse-rfc2822-timestamp "Sat Jul 19 23:53:21 2025") nil) (expect= (parse-timestamp "Sat Jul 19 23:53:21 2025") 1752965601) + (expect= (parse-timestamp "Wed Aug 8 12:51:52 2018") 1533729112) )