From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marcelo de Moraes Serpa Subject: Re: Batch execution and --script Date: Wed, 29 Aug 2012 13:35:45 -0500 Message-ID: References: <3611.1346264968@alphaville> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=485b397dd5bdaa5f3804c86bd302 Return-path: Received: from eggs.gnu.org ([208.118.235.92]:39782) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1T6n7G-0002vs-9N for emacs-orgmode@gnu.org; Wed, 29 Aug 2012 14:35:54 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1T6n7B-00031I-MK for emacs-orgmode@gnu.org; Wed, 29 Aug 2012 14:35:50 -0400 Received: from mail-qa0-f41.google.com ([209.85.216.41]:50674) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1T6n7B-00031D-Gm for emacs-orgmode@gnu.org; Wed, 29 Aug 2012 14:35:45 -0400 Received: by qafk30 with SMTP id k30so4603142qaf.0 for ; Wed, 29 Aug 2012 11:35:45 -0700 (PDT) In-Reply-To: <3611.1346264968@alphaville> 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: nicholas.dokos@hp.com Cc: Org Mode , Nick Daly --485b397dd5bdaa5f3804c86bd302 Content-Type: text/plain; charset=ISO-8859-1 Hi Nick, Thanks for turning it into a concise example :) Is that somewhere in the manual or Worg? Perhaps it should be added. I never contributed to Worg, I will look into how tonight. This is a subject that should be explored more. I see a lot of potential in having CLI .el scripts (i.e taking the emacs GUI out of the equation). - Marcelo. On Wed, Aug 29, 2012 at 1:29 PM, Nick Dokos wrote: > Nick Daly wrote: > > > On Wed, Aug 29, 2012 at 10:47 AM, Marcelo de Moraes Serpa > > wrote: > > > Hey guys, > > > > > > Regarding this: http://orgmode.org/manual/Batch-execution.html > > > > > > I also had success using --script, as in: > > > > > > #!/Applications/Emacs.app/Contents/MacOS/Emacs --script > > > > > > In the top of a .el file. You can then chmod it to be executable and > run it. > > > > Would you mind sharing a simple .el file you'd use that way? The > > site's example is a bash script, and I wonder how much cleaner a .el > > file would be. > > > > Marcelo posted a larger example, but maybe a very small example might be > helpful. Put the following in some file (I called it hello.el but the > name does not really matter): > > --8<---------------cut here---------------start------------->8--- > #! /usr/local/bin/emacs --script > > (message "Hello World!") > --8<---------------cut here---------------end--------------->8--- > > Make it executable: > > chmod +x hello.el > > and run it: > > ./hello.el > > Nick > > --485b397dd5bdaa5f3804c86bd302 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hi Nick,

Thanks for turning it into a concise example :)=

Is that somewhere in the manual or Worg? Perhaps = it should be added. I never contributed to Worg, I will look into how tonig= ht.

This is a subject that should be explored more. I see a= lot of potential in having CLI .el scripts (i.e taking the emacs GUI out o= f the equation).

- Marcelo.



--485b397dd5bdaa5f3804c86bd302--