summaryrefslogtreecommitdiffstats
path: root/emacsconf-publish.el
diff options
context:
space:
mode:
authorSacha Chua <sacha@sachachua.com>2023-10-17 11:56:06 -0400
committerSacha Chua <sacha@sachachua.com>2023-10-17 11:56:06 -0400
commit2df5e7266e07947010ce3cdd430e79f0642f247d (patch)
tree031a268b7dd4a0d3902fc51387572ae4e0aeab26 /emacsconf-publish.el
parent227fe1a45398ebf3f0663bf8c73cd4d7e431b38a (diff)
downloademacsconf-el-2df5e7266e07947010ce3cdd430e79f0642f247d.tar.xz
emacsconf-el-2df5e7266e07947010ce3cdd430e79f0642f247d.zip
update watch pages
Diffstat (limited to 'emacsconf-publish.el')
-rw-r--r--emacsconf-publish.el43
1 files changed, 31 insertions, 12 deletions
diff --git a/emacsconf-publish.el b/emacsconf-publish.el
index a142fd7..827ed8d 100644
--- a/emacsconf-publish.el
+++ b/emacsconf-publish.el
@@ -1948,8 +1948,8 @@ This video is available under the terms of the Creative Commons Attribution-Shar
(defun emacsconf-publish-format-watch-index (info)
(concat
"<!-- Automatically generated by emacsconf-publish-watch-pages -->\n
-<h1>Tracks</h1>"
- "<table width=\"100%\"><tr><th>Watch page</th><th>IRC channel (libera.chat)</th><th>Alternative for streaming player</th><th>Low res</th></tr>\n"
+<h2>Tracks</h2>"
+ "<table width=\"100%\"><tr><th>Watch page</th><th>IRC channel (libera.chat)</th><th>URL for streaming player (ex: mpv, vlc, ffplay)</th><th>Low res</th></tr>\n"
(mapconcat (lambda (track)
(emacsconf-replace-plist-in-string
(append (list :year emacsconf-year) track)
@@ -1990,8 +1990,10 @@ ${resources-info}
(defun emacsconf-publish-schedule-short (info)
(mapconcat (lambda (o)
(emacsconf-replace-plist-in-string
- (append o (list :base-url emacsconf-base-url))
- "<span><a href=\"${base-url}${url}\">${slug}</a> (<a class=\"pad-link\" href=\"${pad-url}\">pad</a>, ${qa-link})</span>"))
+ (append o (list
+ :qa-link-include (emacsconf-surround ", " (plist-get o :qa-link) "" "")
+ :base-url emacsconf-base-url))
+ "<span><a href=\"${base-url}${url}\">${slug}</a> (<a class=\"pad-link\" href=\"${pad-url}\">pad</a>${qa-link-include})</span>"))
info " - "))
(defun emacsconf-publish-page-nav (nav &optional current sep)
@@ -2052,8 +2054,20 @@ ${title-info}
(emacsconf-publish-page-nav nav "watch")
" | ${stream-nav} | <a href=\"https://emacsconf.org/2022/watch/\">Tips for watching/participating</a></div>
+For better performance, we recommend watching <a href=\"${stream-hires}\">${stream-hires}</a> using a streaming media player. Examples:
+
+<ul>
+<li>mpv ${stream-hires}</li>
+<li>vlc ${stream-hires}</li>
+<li>ffplay ${stream-hires}</li>
+</ul>
+
+If you have limited bandwidth, you can watch the low-res stream <a href=\"${480p}\">${480p}</a>.
+
+If you don't have a streaming media player, you can watch using the player below.
+
<video controls class=\"reload\"><source src=\"${stream}\" type=\"video/webm\" /></video>
-<div>Alternatively, load <a href=\"${stream-hires}\">${stream-hires}</a> or <a href=\"${480p}\">${480p}</a> (low-res) in a streaming media player such as MPV.</div>
+
<hr size=\"1\"><div>" (emacsconf-publish-page-nav nav "links") " | ${stream-nav}</div>"
"<div>${brief}</div>
<div class=\"pad-output\"></div>
@@ -2123,9 +2137,17 @@ if (video) {
(when emacsconf-publish-watch-directory
(make-directory (expand-file-name "watch" (expand-file-name emacsconf-year emacsconf-publish-watch-directory)) t)
(with-temp-file (expand-file-name "watch/index.html" (expand-file-name emacsconf-year emacsconf-publish-watch-directory))
- (insert "<html><head><title>Watch EmacsConf</title><link rel=\"stylesheet\" type=\"text/css\" href=\"/style.css\"></link></head><body>" (emacsconf-publish-format-watch-index info)
-
- " <p>
+ (insert
+ (emacsconf-replace-plist-in-string
+ (list
+ :conf-name emacsconf-name
+ :year emacsconf-year
+ :watch-index (emacsconf-publish-format-watch-index info)
+ )
+ "<html><head><title>Watch ${conf-name} ${year}</title><link rel=\"stylesheet\" type=\"text/css\" href=\"/style.css\"></link></head><body>
+<h1>${conf-name} ${year}</h1>
+${watch-index}
+<p>
Depending on which media player you use, you may enter the stream address
in a graphical user interface or provide it as an argument to the program
when launching it from the terminal.
@@ -2157,10 +2179,7 @@ Q&A in the BigBlueButton room, please use headphones or earphones
in order to minimize audio feedback. The link on the talk page
will take you to a waiting room that will automatically refresh
when the host has opened the Q&A.</p>
-
-"
-
- "</body></html>"))
+</body></html>")))
(mapc (lambda (track)
(make-directory (expand-file-name (format "%s/watch/%s" emacsconf-year (plist-get track :id)) emacsconf-publish-watch-directory) t)
(make-directory (expand-file-name (format "%s/watch/%s-480p" emacsconf-year (plist-get track :id)) emacsconf-publish-watch-directory) t)