From 3f9fedd3c829b7c000223c63a74ea70a7b400257 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?tr=C3=A9meur?= Date: Tue, 16 May 2023 00:33:37 +0100 Subject: [PATCH] Undo whatever went wrong with the dwmusic function, add skeleton snippet for single-chapter fic export --- custom/dwpost.el | 5 ++++- snippets/org-mode/ficsetup | 6 ++++++ 2 files changed, 10 insertions(+), 1 deletion(-) create mode 100644 snippets/org-mode/ficsetup diff --git a/custom/dwpost.el b/custom/dwpost.el index d3c433f..f51b277 100644 --- a/custom/dwpost.el +++ b/custom/dwpost.el @@ -64,7 +64,10 @@ (setq music (lastfm-user-get-recent-tracks :user lastfm-user :from 1 :to 1)) (setq music (replace-regexp-in-string (regexp-quote "\" \"") " – " (format "%S" music) nil 'literal)) (sleep-for 1) - (unless (not music) + (if (not music) + (setq music "nil")) + (if (equal music "nil") + (sleep-for 0) (insert (concat "post-music: " (let* ((musicjunk (format "%S" music)) diff --git a/snippets/org-mode/ficsetup b/snippets/org-mode/ficsetup new file mode 100644 index 0000000..7ba235f --- /dev/null +++ b/snippets/org-mode/ficsetup @@ -0,0 +1,6 @@ +# name: ficsetup +# key: ficsetup +# -- +#+TITLE: ${1:tbc} +* fic +$0 \ No newline at end of file