summaryrefslogtreecommitdiffstats
path: root/2022/organizers-notebook/index.org
diff options
context:
space:
mode:
authorSacha Chua <sacha@sachachua.com>2022-12-18 00:55:52 -0500
committerSacha Chua <sacha@sachachua.com>2022-12-18 00:55:52 -0500
commit73284abb6f3f17d80d468de5555c98987052e1bc (patch)
tree82adf8a921aefad63edb5d573ec0da30380d8325 /2022/organizers-notebook/index.org
parentc9a3ac84195af83f6479f2c3a6b72a53b091bde0 (diff)
downloademacsconf-wiki-73284abb6f3f17d80d468de5555c98987052e1bc.tar.xz
emacsconf-wiki-73284abb6f3f17d80d468de5555c98987052e1bc.zip
Automated commit
Diffstat (limited to '2022/organizers-notebook/index.org')
-rw-r--r--2022/organizers-notebook/index.org181
1 files changed, 178 insertions, 3 deletions
diff --git a/2022/organizers-notebook/index.org b/2022/organizers-notebook/index.org
index 29e3ee36..58820930 100644
--- a/2022/organizers-notebook/index.org
+++ b/2022/organizers-notebook/index.org
@@ -714,8 +714,7 @@ https://medium.com/@npolovinkin/how-to-chunk-text-into-paragraphs-using-python-8
:PROPERTIES:
:CREATED: [2022-12-13 Tue 16:37]
:END:
-
-The challenge: make it easier to make sense of an IRC log considering the speaker is responding to lots of people.
+ssh
Possible: thread speaker messages?
Manual:
- search backward to find the lines, put something under
@@ -728,6 +727,182 @@ Manual:
:PROPERTIES:
:CREATED: [2022-12-15 Thu 16:52]
:END:
+*** CANCELLED Trim grail if needed
+CLOSED: [2022-12-16 Fri 21:35]
+:PROPERTIES:
+:CREATED: [2022-12-15 Thu 22:24]
+:END:
+*** DONE I uploaded the Q&A sessions to Toobnix. :sachac:
+CLOSED: [2022-12-16 Fri 13:53]
+:LOGBOOK:
+- State "DONE" from "TODO" [2022-12-16 Fri 13:53]
+:END:
+
+Least extra work if I do it after chapter markers, but I can just do them now and then update them later
+
+#+begin_src emacs-lisp :eval no
+(mapc (lambda (o)
+ (let ((default-directory "~/vendor/PeerTube/"))
+ (when (emacsconf-publish-upload-answers o 'toobnix)
+ (emacsconf-go-to-talk o)
+ (shell-command "xdotool mousemove 1782 370 click 1 sleep 1 key Ctrl+r sleep 4 mousemove 1584 546 click 3 sleep 1 mousemove 1664 746 click 1 mousemove 1584 546 sleep 1 key Alt+Tab sleep 1")
+ (org-entry-put
+ (point) "QA_TOOBNIX"
+ (read-string (format "URL for %s: "
+ (org-entry-get (point) "SLUG")))))))
+ (seq-remove
+ (lambda (o)
+ (or (null (emacsconf-talk-file o "--answers.webm"))
+ (plist-get o :qa-toobnix)))
+ (emacsconf-prepare-for-display (emacsconf-get-talk-info))))
+#+end_src
+*** DONE Upload answers to Youtube :sachac:
+CLOSED: [2022-12-16 Fri 21:35] SCHEDULED: <2022-12-17 Sat>
+:PROPERTIES:
+:CREATED: [2022-12-16 Fri 08:01]
+:header-args: :eval no
+:END:
+:LOGBOOK:
+- State "WAITING" from "SOMEDAY" [2022-12-16 Fri 12:58] \\
+ quota
+:END:
+
+Set eval to yes and work carefully.
+
+#+NAME: not-done
+#+begin_src emacs-lisp
+(defun emacsconf-publish-answers-python (talk)
+ (interactive)
+ (concat "filename = \"\"\"" (emacsconf-talk-file talk "--answers.webm") "\"\"\"\n"
+ "title = \"\"\"" (emacsconf-publish-answers-title talk 100) "\"\"\"\n"
+ "description = \"\"\"" (emacsconf-publish-answers-description talk 'youtube) "\"\"\"\n"))
+(plist-get
+ (seq-find (lambda (talk)
+ (not (or (null (emacsconf-talk-file talk "--answers.webm"))
+ (plist-get talk :qa-youtube))))
+ (emacsconf-prepare-for-display (emacsconf-get-talk-info)))
+ :slug)
+
+
+#+end_src
+
+#+RESULTS: not-done
+:results:
+nil
+:end:
+:end:
+
+quota, continue tomorrow
+**** Setup
+#+begin_src python :dir "/home/sacha/proj/plays" :session plays
+from playwright.sync_api import Playwright, sync_playwright, expect
+from pathlib import Path
+import json
+
+playwright = sync_playwright().start()
+browser = playwright.firefox.launch(headless=False)
+context = browser.new_context()
+page = context.new_page()
+context.add_cookies(json.loads(Path("cookies.json").read_text()))
+page.goto("https://studio.youtube.com/")
+#+end_src
+
+Save the cookies after it's all set up
+
+#+begin_src python :dir "/home/sacha/proj/plays" :session plays
+Path("cookies.json").write_text(json.dumps(cookies))
+#+end_src
+
+#+begin_src python :dir "/home/sacha/proj/plays" :session plays
+context.add_cookies(json.loads(Path("cookies.json").read_text()))
+page.goto("https://studio.youtube.com/channel/UCwuyodzTl_KdEKNuJmeo99A")
+#+end_src
+
+
+#+RESULTS:
+:results:
+:end:
+
+1. Upload the file
+
+#+NAME: create
+#+begin_src python :dir "/home/sacha/proj/plays" :session plays :noweb yes :results silent
+#page.get_by_role("dialog", name="Video processing").get_by_role("button", name="Close").click()
+page.locator("#create-icon").click()
+page.get_by_text("Upload videos").click()
+page.get_by_role("button", name="Select files").click()
+<<talk()>>
+#+end_src
+
+2. Set the talk details and copy the URL.
+
+#+begin_src emacs-lisp :var slug=not-done :var url=set_details :results silent
+(save-window-excursion
+ (emacsconf-go-to-talk (emacsconf-resolve-talk slug))
+ (org-entry-put (point) "QA_YOUTUBE" url))
+#+end_src
+***** Background code
+#+NAME: talk
+#+begin_src emacs-lisp :var slug=not-done :noweb yes
+(let ((talk (emacsconf-resolve-talk slug)))
+ (kill-new (emacsconf-talk-file talk "--answers.webm"))
+ (emacsconf-publish-answers-python talk))
+#+end_src
+
+#+RESULTS: talk
+:results:
+filename = """/home/sacha/proj/emacsconf/cache/emacsconf-2022-health--health-data-journaling-and-visualization-with-org-mode-and-gnuplot--david-otoole--answers.webm"""
+title = """EmacsConf 2022 Q&A: Health data journaling and visualization with Org Mode and gnuplot"""
+description = """David O'Toole (he/him)
+
+This is the Q&A for the talk at https://youtu.be/YmQ1CYMz-OY .
+
+You can view this and other resources using free/libre software at https://emacsconf.org/2022/talks/health .
+This video is available under the terms of the Creative Commons Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.
+"""
+:end:
+
+#+NAME: set_details
+#+begin_src python :dir "/home/sacha/proj/plays" :session plays :results output :noweb yes
+<<talk()>>
+page.locator("#title-textarea").click()
+page.keyboard.press("Control+KeyA")
+page.keyboard.press("Delete")
+page.keyboard.type(title)
+page.locator("#description-textarea #textbox").fill(description)
+page.locator('ytcp-video-metadata-playlists .dropdown-trigger-text').click()
+page.get_by_role("dialog", name="Choose playlists").get_by_text("EmacsConf 2022").click()
+page.get_by_role("button", name="Done").click()
+page.get_by_role("button", name="Show more").click()
+page.get_by_placeholder("Add tag").fill("emacs, emacsconf, answers")
+page.get_by_placeholder("Add tag").click()
+href = page.locator('a.ytcp-video-info').get_attribute('href')
+page.locator("#step-badge-3").click()
+page.locator(".ytcp-video-visibility-select[name=PUBLIC]").click()
+page.get_by_role("button", name="PUBLISH").click()
+print(href)
+#+end_src
+
+#+RESULTS: set_details
+:results:
+https://youtu.be/XTDpzx9QHSI
+:end:
+
+#+RESULTS:
+:results:
+https://youtu.be/Q453L_whGEc
+:end:
+
+*** TODO Add links to Q&A to Youtube video descriptions
+:PROPERTIES:
+:CREATED: [2022-12-16 Fri 14:12]
+:END:
+
+*** SOMEDAY Make a podcast feed of the talks
+:PROPERTIES:
+:CREATED: [2022-12-17 Sat 14:26]
+:END:
+
** TODO Send thanks
:PROPERTIES:
:CUSTOM_ID: thanks
@@ -1501,7 +1676,7 @@ CLOCK: [2022-11-23 Wed 21:52]--[2022-11-23 Wed 22:57] => 1:05
(concat (plist-get o :video-slug) "--main.webm")
emacsconf-cache-dir))
(null (plist-get o :toobnix-url)))
- (format "node dist/server/tools/peertube.js upload -f %s -n %s -l 2 -c 15 -P 2 -t emacs,emacsconf -L en -C emacsconf -d %s"
+ (format "cd ~/vendor/PeerTube; node dist/server/tools/peertube.js upload -f %s -n %s -l 2 -c 15 -P 2 -t emacs,emacsconf -L en -C emacsconf -d %s"
(expand-file-name
(concat (plist-get o :video-slug) "--main.webm")
emacsconf-cache-dir)