From mboxrd@z Thu Jan 1 00:00:00 1970 From: phillip.lord@newcastle.ac.uk (Phillip Lord) Subject: Struggling with new exporter Date: Mon, 22 Sep 2014 20:50:38 +0100 Message-ID: <87a95r4epd.fsf@newcastle.ac.uk> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:54794) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XW9dO-0002Pg-LM for emacs-orgmode@gnu.org; Mon, 22 Sep 2014 15:51:02 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XW9dG-0005aw-AC for emacs-orgmode@gnu.org; Mon, 22 Sep 2014 15:50:54 -0400 Received: from cheviot12.ncl.ac.uk ([128.240.234.12]:58019) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XW9dG-0005aN-01 for emacs-orgmode@gnu.org; Mon, 22 Sep 2014 15:50:46 -0400 Received: from smtpauth-vm.ncl.ac.uk ([10.8.233.129] helo=smtpauth.ncl.ac.uk) by cheviot12.ncl.ac.uk with esmtp (Exim 4.63) (envelope-from ) id 1XW9d9-0002LZ-9s for emacs-orgmode@gnu.org; Mon, 22 Sep 2014 20:50:39 +0100 Received: from cpc7-benw10-2-0-cust228.16-2.cable.virginm.net ([77.98.254.229] helo=localhost) by smtpauth.ncl.ac.uk with esmtpsa (TLSv1:AES128-SHA:128) (Exim 4.63) (envelope-from ) id 1XW9d8-0001HX-Sx for emacs-orgmode@gnu.org; Mon, 22 Sep 2014 20:50:39 +0100 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org I'm rather struggling with the new exporter. I fear I have used a combination of old and new configuration which cannot be helping. I am trying to get publishing working mostly in batch, so that it will work as part of my continuous integration framework. But having it work interactively would be nice also. I have installed the org-mode daily from the Org ELPA. I have a file called book.org, which also includes several other files. I want to publish to HTML and PDF. It would be nice to publish to some kind of chunked HTML also, as the file will get quite long, but for the moment I can live with out this. The headers look like this: #+LATEX_HEADER: \usepackage{tawny} #+LATEX_HEADER: \lstnewenvironment{tawny}{\lstset{style=tawnystyle}}{} #+BIND: org-publishing-directory "./exports" #+BIND: org-latex-custom-lang-environments ((clojure "tawny")) #+BIND: org-latex-listings t Tawny is my own package, and is present in the same location as the org file. It provides the syntax highlighting support latex. Now, by original batch build commands looked like this... (defun build/pdf () (with-current-buffer (find-file-noselect build-source-file) (org-export-as-pdf org-export-headline-levels))) (defun build/html () (init-faces) (setq htmlize-use-rgb-map 'force) (with-current-buffer (find-file-noselect build-source-file)) (org-export-as-html-batch org-export-headline-levels)) but these are using the old org-export functions. My current version looks like this... (defun build/html () (init-faces) (setq htmlize-use-rgb-map 'force) (with-current-buffer (find-file-noselect build-source-file)) (org-html-publish-to-html ;; publishing plist nil ;; output file name "book.html" ;; directory "exports")) Which is crashing with: Debugger entered--Lisp error: (error "`org-publish-cache-get' called, but no cache present") signal(error ("`org-publish-cache-get' called, but no cache present")) error("`org-publish-cache-get' called, but no cache present") Interactively, the publishing works BUT the bind forms appear to do nothing. My source code is coming up verbatim and the publishing directory is being ignored. Any help gratefully recieved! Phil