From 1e7f47df29053c2a197ee4a143f6ea198167b4fc Mon Sep 17 00:00:00 2001 From: Sacha Chua Date: Tue, 26 Sep 2023 12:59:10 -0400 Subject: Recognize multiple time constraints --- emacsconf-publish.el | 87 ++++++++++++++++++++++++++-------------------------- 1 file changed, 44 insertions(+), 43 deletions(-) (limited to 'emacsconf-publish.el') diff --git a/emacsconf-publish.el b/emacsconf-publish.el index 3657012..a8f2495 100644 --- a/emacsconf-publish.el +++ b/emacsconf-publish.el @@ -492,49 +492,50 @@ resources." (timestamp (org-timestamp-from-string (plist-get o :scheduled)))) (emacsconf-replace-plist-in-string (append o - (list :format - (concat (or (plist-get o :video-time) - (plist-get o :time)) - "-min talk" - (if (plist-get o :q-and-a) - (format " followed by %s Q&A%s" - (plist-get o :q-and-a) - (if (eq emacsconf-publishing-phase 'conference) - (format " (%s)" - (if (string-match "live" (plist-get o :q-and-a)) - (if (eq 'after (emacsconf-bbb-status o)) - "done" - (format "" (plist-get o :slug))) - (emacsconf-publish-webchat-link o))) - "")) - "")) - :pad-info - (if emacsconf-publish-include-pads - (format "Etherpad: \n" emacsconf-year (plist-get o :slug)) - "") - :irc-info - (format "Discuss on IRC: [#%s](%s) \n" (plist-get o :channel) - (plist-get o :webchat-url)) - :status-info - (if (member emacsconf-publishing-phase '(cfp program schedule conference)) (format "Status: %s \n" (plist-get o :status-label)) "") - :schedule-info - (if (and (member emacsconf-publishing-phase '(schedule conference)) - (not (emacsconf-talk-all-done-p o)) - (not (string= (plist-get o :status) "CANCELLED"))) - (let ((start (org-timestamp-to-time (org-timestamp-split-range timestamp))) - (end (org-timestamp-to-time (org-timestamp-split-range timestamp t)))) - (format - "
Times in different timezones:
%s
which is the same as:
%s
Find out how to watch and participate
" - (format-time-string "%Y-%m-%dT%H:%M:%SZ" start t) - (format-time-string "%Y-%m-%dT%H:%M:%SZ" end t) - (emacsconf-timezone-string o emacsconf-timezone) - (string-join (emacsconf-timezone-strings - o - (seq-remove (lambda (zone) (string= emacsconf-timezone zone)) - emacsconf-timezones)) "
") - emacsconf-year - (plist-get (emacsconf-get-track (plist-get o :track)) :id))) - ""))) + (list + :format + (concat (or (plist-get o :video-time) + (plist-get o :time)) + "-min talk" + (if (plist-get o :q-and-a) + (format " followed by %s Q&A%s" + (plist-get o :q-and-a) + (if (eq emacsconf-publishing-phase 'conference) + (format " (%s)" + (if (string-match "live" (plist-get o :q-and-a)) + (if (eq 'after (emacsconf-bbb-status o)) + "done" + (format "" (plist-get o :slug))) + (emacsconf-publish-webchat-link o))) + "")) + "")) + :pad-info + (if emacsconf-publish-include-pads + (format "Etherpad: \n" emacsconf-year (plist-get o :slug)) + "") + :irc-info + (format "Discuss on IRC: [#%s](%s) \n" (plist-get o :channel) + (plist-get o :webchat-url)) + :status-info + (if (member emacsconf-publishing-phase '(cfp program schedule conference)) (format "Status: %s \n" (plist-get o :status-label)) "") + :schedule-info + (if (and (member emacsconf-publishing-phase '(schedule conference)) + (not (emacsconf-talk-all-done-p o)) + (not (string= (plist-get o :status) "CANCELLED"))) + (let ((start (org-timestamp-to-time (org-timestamp-split-range timestamp))) + (end (org-timestamp-to-time (org-timestamp-split-range timestamp t)))) + (format + "
Times in different timezones:
%s
which is the same as:
%s
" + (format-time-string "%Y-%m-%dT%H:%M:%SZ" start t) + (format-time-string "%Y-%m-%dT%H:%M:%SZ" end t) + (emacsconf-timezone-string o emacsconf-timezone) + (string-join (emacsconf-timezone-strings + o + (seq-remove (lambda (zone) (string= emacsconf-timezone zone)) + emacsconf-timezones)) "
") + emacsconf-year + (plist-get (emacsconf-get-track (plist-get o :track)) :id))) + ""))) (concat "[[!toc ]] Format: ${format} -- cgit v1.2.3