diff options
author | Sacha Chua <sacha@sachachua.com> | 2020-12-12 01:32:56 -0500 |
---|---|---|
committer | Sacha Chua <sacha@sachachua.com> | 2020-12-12 01:32:56 -0500 |
commit | defbc38cdc86058aa14bb417acdec616103af63f (patch) | |
tree | f7faae6466b2992e7662d3d6401aa9538286e1d5 | |
parent | 1d2f0dec62f3695d50ef4bb1400aa2f71d775135 (diff) | |
download | emacsconf-wiki-defbc38cdc86058aa14bb417acdec616103af63f.tar.xz emacsconf-wiki-defbc38cdc86058aa14bb417acdec616103af63f.zip |
Tweak pad template
-rw-r--r-- | 2020/organizers-notebook.md | 129 | ||||
-rw-r--r-- | 2020/organizers-notebook.org | 317 |
2 files changed, 264 insertions, 182 deletions
diff --git a/2020/organizers-notebook.md b/2020/organizers-notebook.md index 94a8e8d5..16d45bd1 100644 --- a/2020/organizers-notebook.md +++ b/2020/organizers-notebook.md @@ -76,6 +76,7 @@ organizers-notebook.org back to the repo. Note that re-evaluating a defvar won't change the value, so if you want to change the value after this is already loaded, use `(setq ...)`. + (defvar conf/year 2020 "Year of conference.") (defvar conf/buffer-minutes 3 "Number of minutes to use as a buffer between talks.") (defvar conf/timezones '("EST" "America/Los_Angeles" "UTC" "CET" "Asia/Singapore") "List of timezones") (defvar conf/autogenerate-talk-pages nil "Set this to t at the beginning of the conference, when we're still autogenerating individual talk pages. @@ -272,7 +273,8 @@ STREAM - main organizer, CHECK - secondary organizer or volunteer, PAD - organiz (defun conf/format-talk-link (talk) (and talk (if (plist-get talk :talk-id) - (format "<a href=\"/2020/talks/%s\">%s</a>" + (format "<a href=\"/%d/talks/%s\">%s</a>" + year (plist-get talk :talk-id) (plist-get talk :title)) (plist-get talk :title)))) @@ -334,24 +336,26 @@ STREAM - main organizer, CHECK - secondary organizer or volunteer, PAD - organiz (if prev-talk (format "Previous: %s \n" prev-talk) "") (if next-talk (format "Next: %s \n" next-talk) "")))) (insert (format "[[%s title=\"%s\"]] - [[%s copyright=\"Copyright © 2020 %s\"]] + [[%s copyright=\"Copyright © %s %s\"]] - <!-- To edit the talk information, change /2020/info/TALKID.md. Boilerplate automatically generated from submissions.org using conf/generate-schedule-files --->\n + <!-- To edit the talk information, change info/TALKID.md. Boilerplate automatically generated from submissions.org using conf/generate-schedule-files --->\n - %s + %s - [[!inline pages=\"internal(2020/info/%s)\" raw=\"yes\"]] + [[!inline pages=\"internal(%s/info/%s)\" raw=\"yes\"]] - %s + %s - %s + %s - " + " "!meta" (replace-regexp-in-string "\"" "\\\\\"" (plist-get o :title)) - "!meta" + "!meta" + conf/year (plist-get o :speakers) nav-links + conf/year (plist-get o :talk-id) schedule nav-links))) @@ -359,40 +363,77 @@ STREAM - main organizer, CHECK - secondary organizer or volunteer, PAD - organiz talks))) (defun conf/generate-pad-template () - (interactive) - (let ((talks (conf/filter-talks conf/info))) - (with-current-buffer (find-file "pad-template.md") + "Generate a template for copying and pasting into the pad. + Writes it to pad-template.html." + (interactive "p") + (let* ((talks (conf/filter-talks conf/info)) + (text (concat + "<p>Conference info, how to watch/participate: https://emacsconf.org/2020/<br /> + Guidelines for conduct: https://emacsconf.org/conduct/</p> + + <p>Except where otherwise noted, the material on the EmacsConf pad are dual-licensed under the terms of the Creative Commons Attribution-ShareAlike 4.0 International Public License; and the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) an later version. + Copies of these two licenses are included in the EmacsConf wiki repository, in the COPYING.GPL and COPYING.CC-BY-SA files (https://emacsconf.org/COPYING/).</p> + + <p>By contributing to this pad, you agree to make your contributions available under the above licenses. You are also promising that you are the author of your changes, or that you copied them from a work in the public domain or a work released under a free license that is compatible with the above two licenses. DO NOT SUBMIT COPYRIGHTED WORK WITHOUT PERMISSION.</p> + + <p> + This pad is here to be curated by everybody and its rough structure is like this: + <ol><li>General info and license + <li>A section for each talk -> please do add questions and notes + <li>A general feedback section + </ol> + </p> + " + (mapconcat + (lambda (o) + (let ((url (format "https://emacsconf.org/%s/schedule/%s" conf/year (plist-get o :talk-id)))) + (format "-------------------------------------------------------------------------------------------------<br/><strong>Talk%s: %s</strong><br /> + Speaker(s): %s<br /> + Talk page: <a href=\"%s\">%s</a><br /> + Actual start of talk EST: Start of Q&A: End of Q&A: <br /> + <strong>Questions:</strong> + Speakers may answer in any order or skip questions. As much as possible, put your questions at the top level instead of under another question. If adding an answer, please indicate [speaker] or your nick accordingly. Volunteers, please add new slots as ones get filled.<br /> + <ul> + <li>Q1: <ul><li>A: </li></ul></li> + <li>Q2: <ul><li>A: </li></ul></li> + <li>Q3: <ul><li>A: </li></ul></li> + <li>Q4: <ul><li>A: </li></ul></li> + </ul> + + <strong>Links and other notes:</strong> + <ul> + <li>sample text</li> + <li>sample text</li> + <li>sample text</li> + <li>sample text</li> + </ul> + " (plist-get o :talk-id) (plist-get o :title) (plist-get o :speakers) url url))) talks "<br/><br/>\n") + "<br/><br/>-------------------------------------------------------------------------------------------------<br/> + <strong>General Feedback: What went well?</strong><br/><br/> + <ul> + <li>sample text</li> + <li>sample text</li> + <li>sample text</li> + <li>sample text</li> + </ul> + <br /><br /> + -------------------------------------------------------------------------------------------------<br/> + <strong>General Feedback: What to improve?</strong><br/><br/> + <ul> + <li>sample text</li> + <li>sample text</li> + <li>sample text</li> + <li>sample text</li> + </ul> + <br/><br/> + -------------------------------------------------------------------------------------------------<br/> + <strong>Colophon:</strong> + <ul></ul>"))) + (with-current-buffer (find-file "pad-template.html") (erase-buffer) - (insert - (concat - "Conference info, how to watch/participate: <https://emacsconf.org/2020/> - Code of conduct: <https://emacsconf.org/conduct/> - - " - (mapconcat - (lambda (o) - (format "**%s** - Speaker(s): %s - Talk page: <https://emacsconf.org/2020/schedule/%s> - - *Questions:* - - * Put your questions here, most recent on top - * sample text - - *Links:* - - * sample text - * sample text - - *Other notes:* - - * sample text - * sample text - <br> - <br> - " (plist-get o :title) (plist-get o :speakers) (plist-get o :talk-id))) talks " \n \n"))) - (save-buffer)))) + (insert text) + (save-buffer))) + (browse-url-of-file "pad-template.html")) (defun conf/generate-talks-page () (let ((info conf/info)) @@ -706,10 +747,10 @@ Another collaborative pad ### Encode highly-compressed versions -[Compressing video](#org9a70982) +[Compressing video](#orgbdc605d) -<a id="org9a70982"></a> +<a id="orgbdc605d"></a> ### Compressing video diff --git a/2020/organizers-notebook.org b/2020/organizers-notebook.org index 7bff5d4f..a3c81224 100644 --- a/2020/organizers-notebook.org +++ b/2020/organizers-notebook.org @@ -76,6 +76,7 @@ organizers-notebook.org back to the repo. Note that re-evaluating a defvar won't change the value, so if you want to change the value after this is already loaded, use =(setq ...)=. #+begin_src emacs-lisp +(defvar conf/year 2020 "Year of conference.") (defvar conf/buffer-minutes 3 "Number of minutes to use as a buffer between talks.") (defvar conf/timezones '("EST" "America/Los_Angeles" "UTC" "CET" "Asia/Singapore") "List of timezones") (defvar conf/autogenerate-talk-pages nil "Set this to t at the beginning of the conference, when we're still autogenerating individual talk pages. @@ -270,155 +271,195 @@ The total is written to the MIN_TIME_SUM property of this heading" *** Generate schedule file #+begin_src emacs-lisp :results none :eval yes :exports code :tangle "conf.el" - (defun conf/format-talk-link (talk) - (and talk (if (plist-get talk :talk-id) - (format "<a href=\"/2020/talks/%s\">%s</a>" - (plist-get talk :talk-id) - (plist-get talk :title)) - (plist-get talk :title)))) - - (defun conf/format-talk-info-as-schedule (info) - (format "<table width=\"100%%\">%s</table>" - (mapconcat - (lambda (o) - (let* ((time-fmt "%l:%M %p") - (timestamp (org-timestamp-from-string (plist-get o :scheduled))) - (start (if timestamp (format-time-string time-fmt (org-timestamp-to-time (org-timestamp-split-range timestamp))) "")) - (end (if timestamp (format-time-string time-fmt (org-timestamp-to-time (org-timestamp-split-range timestamp t))) "")) - (title (plist-get o :title)) - (speakers (plist-get o :speakers))) - (if (eq (plist-get o :type) 'headline) - (format "<tr><td colspan=\"4\"><strong>%s<strong></td></tr>" - (if (plist-get o :talk-id) - (conf/format-talk-link o) - title)) - (format "<tr><td width=100>~%s</td><td width=100>~%s</td><td>%s</td><td>%s</td></tr>" - start end (conf/format-talk-link o) speakers)))) - (cdr info) "\n"))) - - (defun conf/filter-talks (info) - (seq-filter (lambda (o) (plist-get o :talk-id)) info)) - - (defun conf/split-out-talk-information () - (interactive) - (let ((talks (conf/filter-talks conf/info))) - (mapc (lambda (o) - (with-temp-buffer - (insert - (format "# %s\n%s\n\n%s" - (plist-get o :title) - (plist-get o :speakers) - (plist-get o :info))) - (write-file (expand-file-name (format "%s.md" (plist-get o :talk-id)) "info")))) - talks))) - - (defun conf/format-talk-pages (info) - (let* ((talks (conf/filter-talks info)) - (next-talks (cdr talks)) - (prev-talks (cons nil talks))) - (mapc (lambda (o) - (with-temp-buffer - (let* ((timestamp (org-timestamp-from-string (plist-get o :scheduled))) - (next-talk (conf/format-talk-link (pop next-talks))) - (prev-talk (conf/format-talk-link (pop prev-talks))) - (schedule (mapconcat - (lambda (tz) - (format "%s - %s" - (format-time-string "%A, %b %e %Y, ~%l:%M %p" - (org-timestamp-to-time (org-timestamp-split-range timestamp)) tz) - (format-time-string "%l:%M %p %Z" - (org-timestamp-to-time (org-timestamp-split-range timestamp t)) tz))) - conf/timezones - " \n")) - (nav-links (format "Back to the [[schedule]] \n%s%s" - (if prev-talk (format "Previous: %s \n" prev-talk) "") - (if next-talk (format "Next: %s \n" next-talk) "")))) - (insert (format "[[%s title=\"%s\"]] - [[%s copyright=\"Copyright © 2020 %s\"]] - - <!-- To edit the talk information, change /2020/info/TALKID.md. Boilerplate automatically generated from submissions.org using conf/generate-schedule-files --->\n + (defun conf/format-talk-link (talk) + (and talk (if (plist-get talk :talk-id) + (format "<a href=\"/%d/talks/%s\">%s</a>" + year + (plist-get talk :talk-id) + (plist-get talk :title)) + (plist-get talk :title)))) + + (defun conf/format-talk-info-as-schedule (info) + (format "<table width=\"100%%\">%s</table>" + (mapconcat + (lambda (o) + (let* ((time-fmt "%l:%M %p") + (timestamp (org-timestamp-from-string (plist-get o :scheduled))) + (start (if timestamp (format-time-string time-fmt (org-timestamp-to-time (org-timestamp-split-range timestamp))) "")) + (end (if timestamp (format-time-string time-fmt (org-timestamp-to-time (org-timestamp-split-range timestamp t))) "")) + (title (plist-get o :title)) + (speakers (plist-get o :speakers))) + (if (eq (plist-get o :type) 'headline) + (format "<tr><td colspan=\"4\"><strong>%s<strong></td></tr>" + (if (plist-get o :talk-id) + (conf/format-talk-link o) + title)) + (format "<tr><td width=100>~%s</td><td width=100>~%s</td><td>%s</td><td>%s</td></tr>" + start end (conf/format-talk-link o) speakers)))) + (cdr info) "\n"))) + + (defun conf/filter-talks (info) + (seq-filter (lambda (o) (plist-get o :talk-id)) info)) + + (defun conf/split-out-talk-information () + (interactive) + (let ((talks (conf/filter-talks conf/info))) + (mapc (lambda (o) + (with-temp-buffer + (insert + (format "# %s\n%s\n\n%s" + (plist-get o :title) + (plist-get o :speakers) + (plist-get o :info))) + (write-file (expand-file-name (format "%s.md" (plist-get o :talk-id)) "info")))) + talks))) + + (defun conf/format-talk-pages (info) + (let* ((talks (conf/filter-talks info)) + (next-talks (cdr talks)) + (prev-talks (cons nil talks))) + (mapc (lambda (o) + (with-temp-buffer + (let* ((timestamp (org-timestamp-from-string (plist-get o :scheduled))) + (next-talk (conf/format-talk-link (pop next-talks))) + (prev-talk (conf/format-talk-link (pop prev-talks))) + (schedule (mapconcat + (lambda (tz) + (format "%s - %s" + (format-time-string "%A, %b %e %Y, ~%l:%M %p" + (org-timestamp-to-time (org-timestamp-split-range timestamp)) tz) + (format-time-string "%l:%M %p %Z" + (org-timestamp-to-time (org-timestamp-split-range timestamp t)) tz))) + conf/timezones + " \n")) + (nav-links (format "Back to the [[schedule]] \n%s%s" + (if prev-talk (format "Previous: %s \n" prev-talk) "") + (if next-talk (format "Next: %s \n" next-talk) "")))) + (insert (format "[[%s title=\"%s\"]] + [[%s copyright=\"Copyright © %s %s\"]] + + <!-- To edit the talk information, change info/TALKID.md. Boilerplate automatically generated from submissions.org using conf/generate-schedule-files --->\n %s - [[!inline pages=\"internal(2020/info/%s)\" raw=\"yes\"]] + [[!inline pages=\"internal(%s/info/%s)\" raw=\"yes\"]] %s %s " - "!meta" - (replace-regexp-in-string "\"" "\\\\\"" (plist-get o :title)) - "!meta" - (plist-get o :speakers) - nav-links - (plist-get o :talk-id) - schedule - nav-links))) - (write-file (format "talks/%s.md" (plist-get o :talk-id))))) - talks))) - - (defun conf/generate-pad-template () - (interactive) - (let ((talks (conf/filter-talks conf/info))) - (with-current-buffer (find-file "pad-template.md") - (erase-buffer) - (insert - (concat - "Conference info, how to watch/participate: <https://emacsconf.org/2020/> - Code of conduct: <https://emacsconf.org/conduct/> - + "!meta" + (replace-regexp-in-string "\"" "\\\\\"" (plist-get o :title)) + "!meta" + conf/year + (plist-get o :speakers) + nav-links + conf/year + (plist-get o :talk-id) + schedule + nav-links))) + (write-file (format "talks/%s.md" (plist-get o :talk-id))))) + talks))) + + (defun conf/generate-pad-template () + "Generate a template for copying and pasting into the pad. + Writes it to pad-template.html." + (interactive "p") + (let* ((talks (conf/filter-talks conf/info)) + (text (concat + "<p>Conference info, how to watch/participate: https://emacsconf.org/2020/<br /> + Guidelines for conduct: https://emacsconf.org/conduct/</p> + + <p>Except where otherwise noted, the material on the EmacsConf pad are dual-licensed under the terms of the Creative Commons Attribution-ShareAlike 4.0 International Public License; and the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) an later version. + Copies of these two licenses are included in the EmacsConf wiki repository, in the COPYING.GPL and COPYING.CC-BY-SA files (https://emacsconf.org/COPYING/).</p> + + <p>By contributing to this pad, you agree to make your contributions available under the above licenses. You are also promising that you are the author of your changes, or that you copied them from a work in the public domain or a work released under a free license that is compatible with the above two licenses. DO NOT SUBMIT COPYRIGHTED WORK WITHOUT PERMISSION.</p> + + <p> + This pad is here to be curated by everybody and its rough structure is like this: + <ol><li>General info and license + <li>A section for each talk -> please do add questions and notes + <li>A general feedback section + </ol> + </p> " - (mapconcat - (lambda (o) - (format "**%s** - Speaker(s): %s - Talk page: <https://emacsconf.org/2020/schedule/%s> - - ,*Questions:* - - ,* Put your questions here, most recent on top - ,* sample text - - ,*Links:* - - ,* sample text - ,* sample text - - ,*Other notes:* - - ,* sample text - ,* sample text - <br> - <br> - " (plist-get o :title) (plist-get o :speakers) (plist-get o :talk-id))) talks " \n \n"))) - (save-buffer)))) - - (defun conf/generate-talks-page () - (let ((info conf/info)) - (with-temp-buffer - (find-file "talk-details.md") - (erase-buffer) - (insert (format "<table><thead><th>Duration</th><th>Title</th><th>Speakers</th></thead><tbody>%s</tbody></table>" - (mapconcat - (lambda (o) - (let* ((title (plist-get o :title)) - (speakers (plist-get o :speakers))) - (if (null (plist-get o :talk-id)) - (format "<tr><td colspan=\"3\">%s</td></tr>" (conf/format-talk-link o)) - (format "<tr><td>%s</td><td>%s</td><td>%s</td><tr>" - (plist-get o :duration) - (conf/format-talk-link o) - (plist-get o :speakers))))) - info "\n"))) - (save-buffer)))) - - (defun conf/generate-schedule-files (&optional filename) - (interactive) + (mapconcat + (lambda (o) + (let ((url (format "https://emacsconf.org/%s/schedule/%s" conf/year (plist-get o :talk-id)))) + (format "-------------------------------------------------------------------------------------------------<br/><strong>Talk%s: %s</strong><br /> + Speaker(s): %s<br /> + Talk page: <a href=\"%s\">%s</a><br /> + Actual start of talk EST: Start of Q&A: End of Q&A: <br /> + <strong>Questions:</strong> + Speakers may answer in any order or skip questions. As much as possible, put your questions at the top level instead of under another question. If adding an answer, please indicate [speaker] or your nick accordingly. Volunteers, please add new slots as ones get filled.<br /> + <ul> + <li>Q1: <ul><li>A: </li></ul></li> + <li>Q2: <ul><li>A: </li></ul></li> + <li>Q3: <ul><li>A: </li></ul></li> + <li>Q4: <ul><li>A: </li></ul></li> + </ul> + + <strong>Links and other notes:</strong> + <ul> + <li>sample text</li> + <li>sample text</li> + <li>sample text</li> + <li>sample text</li> + </ul> + " (plist-get o :talk-id) (plist-get o :title) (plist-get o :speakers) url url))) talks "<br/><br/>\n") + "<br/><br/>-------------------------------------------------------------------------------------------------<br/> + <strong>General Feedback: What went well?</strong><br/><br/> + <ul> + <li>sample text</li> + <li>sample text</li> + <li>sample text</li> + <li>sample text</li> + </ul> + <br /><br /> + -------------------------------------------------------------------------------------------------<br/> + <strong>General Feedback: What to improve?</strong><br/><br/> + <ul> + <li>sample text</li> + <li>sample text</li> + <li>sample text</li> + <li>sample text</li> + </ul> + <br/><br/> + -------------------------------------------------------------------------------------------------<br/> + <strong>Colophon:</strong> + <ul></ul>"))) + (with-current-buffer (find-file "pad-template.html") + (erase-buffer) + (insert text) + (save-buffer))) + (browse-url-of-file "pad-template.html")) + + (defun conf/generate-talks-page () + (let ((info conf/info)) (with-temp-buffer - (insert (conf/format-talk-info-as-schedule conf/info)) - (write-file "schedule-details.md")) - (when conf/autogenerate-talk-pages (conf/format-talk-pages conf/info))) + (find-file "talk-details.md") + (erase-buffer) + (insert (format "<table><thead><th>Duration</th><th>Title</th><th>Speakers</th></thead><tbody>%s</tbody></table>" + (mapconcat + (lambda (o) + (let* ((title (plist-get o :title)) + (speakers (plist-get o :speakers))) + (if (null (plist-get o :talk-id)) + (format "<tr><td colspan=\"3\">%s</td></tr>" (conf/format-talk-link o)) + (format "<tr><td>%s</td><td>%s</td><td>%s</td><tr>" + (plist-get o :duration) + (conf/format-talk-link o) + (plist-get o :speakers))))) + info "\n"))) + (save-buffer)))) + + (defun conf/generate-schedule-files (&optional filename) + (interactive) + (with-temp-buffer + (insert (conf/format-talk-info-as-schedule conf/info)) + (write-file "schedule-details.md")) + (when conf/autogenerate-talk-pages (conf/format-talk-pages conf/info))) #+end_src Set the info based on submissions.org. |