From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nick Dokos Subject: Re: Export an org file from the command line in the background Date: Wed, 19 Oct 2011 18:37:10 -0400 Message-ID: <9038.1319063830@alphaville.americas.hpqcorp.net> References: <20111019162146.GA24998@client199-154.wlan.hu-berlin.de> <81fwip3q0k.fsf@gmail.com> <20111019201437.GA28039@kenny.fritz.box> <6830.1319058741@alphaville.americas.hpqcorp.net> <20111019222850.GB28039@kenny.fritz.box> Reply-To: nicholas.dokos@hp.com Return-path: Received: from eggs.gnu.org ([140.186.70.92]:38767) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RGel8-0005vA-Dl for emacs-orgmode@gnu.org; Wed, 19 Oct 2011 18:37:15 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RGel6-0002B8-VK for emacs-orgmode@gnu.org; Wed, 19 Oct 2011 18:37:14 -0400 Received: from g1t0026.austin.hp.com ([15.216.28.33]:47157) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RGel6-0002Av-Qf for emacs-orgmode@gnu.org; Wed, 19 Oct 2011 18:37:12 -0400 Received: from g1t0039.austin.hp.com (g1t0039.austin.hp.com [16.236.32.45]) by g1t0026.austin.hp.com (Postfix) with ESMTP id 65ED8C0C7 for ; Wed, 19 Oct 2011 22:37:11 +0000 (UTC) In-Reply-To: Message from Viktor Rosenfeld of "Thu, 20 Oct 2011 00:28:50 +0200." <20111019222850.GB28039@kenny.fritz.box> 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 Cc: nicholas.dokos@hp.com Viktor Rosenfeld wrote: > ... > One more question, it doesn't matter if I put the code in the > file that is loaded via -l or in the --eval block, correct? I've > included the code in the my org file, so I can tangle it. I find it > better to have all the Emacs code in one location. > Correct. Which is preferable is very much a matter of usage patterns and taste. > Here's what I came up with: > > (add-to-list 'load-path (expand-file-name "~/unix/src/org-mode/lisp")) > (add-to-list 'load-path (expand-file-name "~/unix/src/org-mode/contrib/lisp")) > (require 'org) > (require 'ob-sh) > (require 'ansi-color) > (let ((ansi-color-for-comint-mode nil) > (org-confirm-babel-evaluate nil) > (org-use-sub-superscripts nil)) > (find-file "~/org/projects/macports/macports.org") > (org-with-point-at > (org-id-find "83583083-47B7-44DF-8474-1C6D03491C97" 'marker) > (org-babel-execute-subtree)) > (org-export-as-html t) > (kill-buffer)) You don't need the kill-buffer if emacs is just going to exit. But it doesn't hurt. Nick