summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSacha Chua <sacha@sachachua.com>2022-10-05 12:14:40 -0400
committerSacha Chua <sacha@sachachua.com>2022-10-05 12:14:40 -0400
commit8fc476a22b53047e1e93c58b538fe733f0c87b42 (patch)
treec27bc391640c80cac6481c268b855c91a03bf29b
parent193f6d72f4041dd7121ccc4a1e4895aa0f2a52e1 (diff)
downloademacsconf-el-8fc476a22b53047e1e93c58b538fe733f0c87b42.tar.xz
emacsconf-el-8fc476a22b53047e1e93c58b538fe733f0c87b42.zip
Add emacsconf-publish-add-talk function
Diffstat (limited to '')
-rw-r--r--emacsconf-publish.el22
1 files changed, 16 insertions, 6 deletions
diff --git a/emacsconf-publish.el b/emacsconf-publish.el
index ef50d04..5fb470b 100644
--- a/emacsconf-publish.el
+++ b/emacsconf-publish.el
@@ -50,6 +50,14 @@
(emacsconf-generate-after-page info))
(emacsconf-generate-main-schedule))
+(defun emacsconf-publish-add-talk ()
+ "Add the current talk to the wiki."
+ (interactive)
+ (emacsconf-update-talk)
+ (emacsconf-generate-info-pages)
+ (emacsconf-generate-main-schedule)
+ (magit-status-setup-buffer emacsconf-directory))
+
(defun emacsconf-update-conf-html ()
"Update the schedules and export the page so I can easily review it."
(interactive)
@@ -69,13 +77,15 @@
(org-html-export-to-html))))
-(defun emacsconf-regenerate-wiki ()
+(defun emacsconf-regenerate-wiki (&optional force)
(interactive)
- (let ((info (emacsconf-get-talk-info)))
- (emacsconf-generate-info-pages info)
- (emacsconf-generate-main-schedule info)
- (emacsconf-generate-talk-pages info t)
- (magit-status emacsconf-directory)))
+ (when
+ (let ((info (emacsconf-get-talk-info))
+ (force (or force (yes-or-no-p "Overwrite existing talk pages? "))))
+ (emacsconf-generate-info-pages info)
+ (emacsconf-generate-main-schedule info)
+ (emacsconf-generate-talk-pages info force)
+ (magit-status emacsconf-directory))))
(defun emacsconf-update-schedules-in-wiki ()
(emacsconf-generate-info-pages)