From 2e8faba3a5e5ce0fe8a542733d97c473dcb205cf Mon Sep 17 00:00:00 2001 From: Sacha Chua Date: Sat, 18 Dec 2021 00:41:11 -0500 Subject: Add Youtube and Toobnix to CSV --- emacsconf-publish.el | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) (limited to 'emacsconf-publish.el') diff --git a/emacsconf-publish.el b/emacsconf-publish.el index 994af0c..17d8122 100644 --- a/emacsconf-publish.el +++ b/emacsconf-publish.el @@ -690,7 +690,11 @@ Columns are: slug,title,speakers,talk page url,video url,duration,sha." (plist-get o :video-slug)) date (format-seconds "%02h:%z%02m:%02s" (/ (compile-media-get-file-duration-ms main-video) 1000)) - (string-trim (shell-command-to-string (concat "sha1sum -b " (shell-quote-argument main-video) " | cut -d ' ' -f 1")))) + (if (file-exists-p main-video) + (string-trim (shell-command-to-string (concat "sha1sum -b " (shell-quote-argument main-video) " | cut -d ' ' -f 1"))) + "") + (or (plist-get o :youtube-url) "") + (or (plist-get o :toobnix-url) "")) (if (plist-get o :qa-public) (list (concat emacsconf-name " " emacsconf-year) @@ -704,11 +708,14 @@ Columns are: slug,title,speakers,talk page url,video url,duration,sha." (plist-get o :video-slug)) date (format-seconds "%02h:%z%02m:%02s" (/ (compile-media-get-file-duration-ms qa-video) 1000)) - (string-trim (shell-command-to-string (concat "sha1sum -b " (shell-quote-argument qa-video) " | cut -d ' ' -f 1"))) - )))))) + (if (file-exists-p qa-video) + (string-trim (shell-command-to-string (concat "sha1sum -b " (shell-quote-argument qa-video) " | cut -d ' ' -f 1"))) + "") + (or (plist-get o :qa-youtube) "") + (or (plist-get o :qa-toobnix) ""))))))) (emacsconf-public-talks (emacsconf-get-talk-info)))))) (insert (orgtbl-to-csv - (cons '("Conference" "Slug" "Title" "Speakers" "Talk page URL" "Video URL" "Date" "Duration" "SHA") + (cons '("Conference" "Slug" "Title" "Speakers" "Talk page URL" "Video URL" "Date" "Duration" "SHA" "Youtube URL" "Toobnix URL") results) nil))))) -- cgit v1.2.3