|
From: | Mark Elston |
Subject: | Re: [Orgmode] RFC: Consistent Latex (& html) publishing environment |
Date: | Fri, 19 Nov 2010 11:45:19 -0800 |
User-agent: | Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.9.2.12) Gecko/20101027 Thunderbird/3.1.6 |
On 11/18/2010 8:10 PM, Russell Adams wrote:
On Thu, Nov 18, 2010 at 10:51:49PM -0500, Nick Dokos wrote:[This doesn't seem to have made it out to the list for some reason, so trying again.] Russell Adams<address@hidden> wrote:... This is great, but pops up an emacs session. If I run emacs in --batch mode, it won't load my init file and so loses some of my export customizations...You can load your init file explicitly: emacs --batch --load<init-file> ...Certainly! And yet, should I be depending on my init file while trying to provide a consistent environment across documents? That's the crux of the matter. Put everything into init files and use it for everything when it seems to need customization, or make a document completely selfcontained and somehow sync settings across docs? That's why I was asking how other folks accomplish similar tasks. Thanks.
Russell, I do something similar. I use SCons instead of make but the idea is the same. I have extracted all my org-specific functionality into a separate .el file that I load on normal startup as a part of my overall _emacs loading. When doing batch processing I have a cut-down version of my _emacs file which sets up only the paths, loads my org-specific .el file and also loads my custom.el file. The command I use is: <emacs> -batch -l <org_el> -eval "(progn (find-file \"<project_org_file>\") (org-export-as-latex 4))" where the items in <> provide the relevant paths to the indicated files. This guarantees I have the same org-mode setup interactively as well as in batch mode so there are no surprises on generation. Of course, SCons already knows how to build pdf files from latex so it is trivial from there to do the remaining generation... Mark
[Prev in Thread] | Current Thread | [Next in Thread] |