From 22f9437d930e9c812dce67129ba6399aa1122a69 Mon Sep 17 00:00:00 2001 From: not manx Date: Wed, 22 Jul 2020 23:59:18 +0000 Subject: [PATCH] Add quote-block --- README.org | 2 +- ox-plumhtml.el | 10 +++++++--- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/README.org b/README.org index 1f4365c..88d17a3 100644 --- a/README.org +++ b/README.org @@ -4,7 +4,7 @@ extensions to [[https://github.com/balddotcat/ox-slimhtml][ox-slimhtml]]. Used to publish words I write. ** Installation -You want to clone the repo, cd to it then do ~M-x +You want to [[https://github.com/C-xC-c/ox-plumhtml.git][clone]] [[https://git.flanchan.moe/c-xc-c/ox-plumhtml.git][the]] [[public@plum.moe:ox-plumhtml][repo]], cd to it then do ~M-x package-install-file~ on ~ox-plumhtml.el~ ** Header IDs In org-mode you can do something like diff --git a/ox-plumhtml.el b/ox-plumhtml.el index a5fbf1e..b09b0e8 100644 --- a/ox-plumhtml.el +++ b/ox-plumhtml.el @@ -89,12 +89,15 @@ Uses for table headers" (format "%s" contents) (format "%s" contents))) -(defun ox-plumhtml-code (code contents info) +(defun ox-plumhtml-code (code _contents _info) (format "%s" (org-html-do-format-code (org-element-property :value code)))) -(defun ox-plumhtml-verbatim (verbatim contents info) +(defun ox-plumhtml-verbatim (verbatim _contents _info) (format "%s" (org-element-property :value verbatim))) +(defun ox-plumhtml-quote-block (_quote-block contents _info) + (format "
\n%s
" contents)) + (defun ox-plumhtml-headline (headline contents info) (let* ((text (org-export-data (org-element-property :title headline) info)) (level (org-export-get-relative-level headline info)) @@ -163,7 +166,8 @@ INFO is a plist holding contextual information." (code . ox-plumhtml-code) (verbatim . ox-plumhtml-verbatim) (headline . ox-plumhtml-headline) - (link . ox-plumhtml-link))) + (link . ox-plumhtml-link) + (quote-block . ox-plumhtml-quote-block))) ;;;###autoload (defun ox-plumhtml-publish-to-html (plist filename pub-dir)