aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLee Hinman <dakrone@users.noreply.github.com>2016-09-04 14:11:19 -0600
committerGitHub <noreply@github.com>2016-09-04 14:11:19 -0600
commit921289bc2c84915fe3bf3724f1ca94a5eb816510 (patch)
treec9e7ba3717f6ddbbfc1758f060be1e9f235f5d24
parentd61c284f7b450e99a201a56e939bc6bb9110d2b5 (diff)
parente36779cca46916a0fcc96ada63045c8ce6aaa3e5 (diff)
downloadox-tufte-921289bc2c84915fe3bf3724f1ca94a5eb816510.tar.gz
ox-tufte-921289bc2c84915fe3bf3724f1ca94a5eb816510.zip
Merge pull request #2 from jonnay/add-publishing-fn
Add publishing function
-rw-r--r--ox-tufte.el18
1 files changed, 18 insertions, 0 deletions
diff --git a/ox-tufte.el b/ox-tufte.el
index 3e2f6b2..dea1901 100644
--- a/ox-tufte.el
+++ b/ox-tufte.el
@@ -213,6 +213,24 @@ Return output file's name."
"<!-- %s --><!-- %s -->")))
(org-export-to-file 'tufte-html outfile async subtreep visible-only)))
+
+;;; publishing function
+
+;;;###autoload
+(defun org-html-publish-to-tufte-html (plist filename pub-dir)
+ "Publish an org file to Tufte-styled HTML.
+
+PLIST is the property list for the given project. FILENAME is
+the filename of the Org file to be published. PUB-DIR is the
+publishing directory.
+
+Return output file name."
+ (org-publish-org-to 'tufte-html filename
+ (concat "." (or (plist-get plist :html-extension)
+ org-html-extension
+ "html"))
+ plist pub-dir))
+
(provide 'ox-tufte)
;;; ox-tufte.el ends here