From 2d4b276a67ab256220a11442f52f13adb4be6d9b Mon Sep 17 00:00:00 2001 From: Daneel Date: Wed, 25 Feb 2026 15:52:02 +0100 Subject: [PATCH] calfw capture: fix calendar-day-name args (use date list, not encode-time) --- config.el | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/config.el b/config.el index 0b6c1ba..fa4c546 100644 --- a/config.el +++ b/config.el @@ -1621,7 +1621,7 @@ Formats matching what org-caldav/ox-icalendar export correctly: (y (calendar-extract-year date)) (m (calendar-extract-month date)) (d (calendar-extract-day date)) - (dow (calendar-day-name (encode-time 0 0 0 d m y) nil t)) + (dow (calendar-day-name date nil t)) (start-time (read-string "Start time (HH:MM, empty=all-day): ")) (end-input (unless (string-empty-p start-time) (read-string "End time or end date (HH:MM / YYYY-MM-DD / YYYY-MM-DD HH:MM, empty=same day open): ")))) @@ -1633,7 +1633,7 @@ Formats matching what org-caldav/ox-icalendar export correctly: (format "<%04d-%02d-%02d %s>" y m d dow) (let* ((parsed (parse-time-string (concat end-date " 00:00"))) (ed (nth 3 parsed)) (em (nth 4 parsed)) (ey (nth 5 parsed)) - (edow (calendar-day-name (encode-time 0 0 0 ed em ey) nil t))) + (edow (calendar-day-name (list em ed ey) nil t))) (format "<%04d-%02d-%02d %s>--<%04d-%02d-%02d %s>" y m d dow ey em ed edow))))) ;; Timed event - check if end contains a date (multi-day) ((and end-input (not (string-empty-p end-input)) @@ -1644,7 +1644,7 @@ Formats matching what org-caldav/ox-icalendar export correctly: (end-date-part (substring end-input 0 10)) (parsed (parse-time-string (concat end-date-part " 00:00"))) (ed (nth 3 parsed)) (em (nth 4 parsed)) (ey (nth 5 parsed)) - (edow (calendar-day-name (encode-time 0 0 0 ed em ey) nil t))) + (edow (calendar-day-name (list em ed ey) nil t))) (if (string-empty-p end-time-part) (format "<%04d-%02d-%02d %s %s>--<%04d-%02d-%02d %s>" y m d dow start-time ey em ed edow)