emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* org-export-async-init-file
@ 2013-09-29 18:02 Thomas S. Dye
  2013-09-29 18:51 ` org-export-async-init-file Rasmus
  0 siblings, 1 reply; 4+ messages in thread
From: Thomas S. Dye @ 2013-09-29 18:02 UTC (permalink / raw)
  To: Org-mode

Aloha all,

I've been following up on John Kitchin's recipe for creating a pdf file
compendium that can be used as the supplementary material for a journal
article.  The journal I'm targeting provides a list of LaTeX packages
that must be used exactly, without omissions or additions.

John's recipe uses the LaTeX package attachfile, which is not on the
list of packages that can be used in preparing the journal article.  It
is OK to use attachfile to prepare the pdf file distributed as supplementary
material. 

I'm trying to set up the Org-mode file to use asynchronous export, both
for the paper and for the supplementary material.  I want to use one
init file when I export the paper, and a different init file when I
export the subtree that contains the supplementary material.

My question: how to change the value of org-export-async-init-file when I
export the subtree?

In the spirit of an ECM, I offer the following EIM to illustrate what
I'm trying to do.

#+TITLE: Paper
#+LATEX_CLASS: journal-article

* Paper Section 1
* Paper Section 2
* Supplementary Material

Describe supplementary material ...

** Supplementary Material Document                                 :noexport:
   :PROPERTIES:
   :EXPORT_FILE_NAME: supplementary-material
   :EXPORT_TITLE: Supplementary Material for Paper
   :EXPORT_LATEX_CLASS: journal-article-supplement
   :END:

* Editing setup                                                    :noexport:
#+name: editing-setup
#+begin_src emacs-lisp
  (require 'ox-latex)
  (setq org-export-in-background t)
  (setq org-export-async-debug t)
  (setq org-export-async-init-file (expand-file-name "init-journal-article.el"))
...
#+end_src

* Initialization File for Journal Article                          :noexport:

#+name: export-setup-journal-article
#+header: :tangle init-journal-article.el
#+begin_src emacs-lisp
  (setq org-latex-packages-alist nil)
  (add-to-list 'org-latex-packages-alist '("" "setspace"))
...
#+end_src

* Initialization File for Journal Article Supplementary Material   :noexport:

#+name: export-setup-journal-article-supplement
#+header: :tangle init-journal-article-supplement.el
#+begin_src emacs-lisp
  (setq org-latex-packages-alist nil)
  (add-to-list 'org-latex-packages-alist '("" "setspace"))
  (add-to-list 'org-latex-packages-alist '("" "attachfile"))
...
#+end_src

All the best,
Tom
-- 
Thomas S. Dye
http://www.tsdye.com

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2013-09-30  9:24 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-09-29 18:02 org-export-async-init-file Thomas S. Dye
2013-09-29 18:51 ` org-export-async-init-file Rasmus
2013-09-29 22:02   ` org-export-async-init-file Thomas S. Dye
2013-09-30  9:24   ` org-export-async-init-file Sebastien Vauban

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).