emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Ethan Ligon <ligon@are.berkeley.edu>
To: "Emacs-orgmode@gnu.org" <emacs-orgmode@gnu.org>
Subject: [PATCH] org.texi: Replace broken example script for batch execution
Date: Thu, 07 Apr 2016 21:05:27 +0000	[thread overview]
Message-ID: <CAJ+2YJP4eOh9=2moAcMm9ihU_ZC9eWQK+TLCG-qPTrjDZH8tOQ@mail.gmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 1642 bytes --]

There is an example bash script in section  14.12 of the org manual which
is meant to tangle source blocks from a supplied list of org files.

The present version is broken in several small ways (it appears to date
from a period when babel was still part of contrib), and requires a
hard-coded specification of the path ORG_HOME.

I've fixed the issue with ORG_HOME, another issue with grepping for strings
that no longer are emitted by ob-tangle, and removed some obsolete
dependencies.

I'm finding the corrected script a useful thing to call from makefiles.

-Ethan

* doc/org.texi: Example bash script to tangle from *.org file was broken
and obsolete; fixed to now work with recent versions of org.
---
 doc/org.texi | 14 ++++++--------
 1 file changed, 6 insertions(+), 8 deletions(-)

diff --git a/doc/org.texi b/doc/org.texi
index 8b8dc65..f935692 100644
--- a/doc/org.texi
+++ b/doc/org.texi
@@ -16838,14 +16838,12 @@ for i in $@@; do
 done

 emacs -Q --batch \
---eval "(progn
-(add-to-list 'load-path (expand-file-name \"~/src/org/lisp/\"))
-(add-to-list 'load-path (expand-file-name \"~/src/org/contrib/lisp/\" t))
-(require 'org)(require 'org-exp)(require 'ob)(require 'ob-tangle)
-(mapc (lambda (file)
-       (find-file (expand-file-name file \"$DIR\"))
-       (org-babel-tangle)
-       (kill-buffer)) '($FILES)))" 2>&1 |grep tangled
+     --eval "(progn
+     (require 'org)(require 'ob)(require 'ob-tangle)
+     (mapc (lambda (file)
+            (find-file (expand-file-name file \"$DIR\"))
+            (org-babel-tangle)
+            (kill-buffer)) '($FILES)))" 2>&1 |grep -i tangled
 @end example

 @node Miscellaneous

[-- Attachment #2: Type: text/html, Size: 2308 bytes --]

             reply	other threads:[~2016-04-07 21:05 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-04-07 21:05 Ethan Ligon [this message]
2016-04-09 21:17 ` [PATCH] org.texi: Replace broken example script for batch execution Nicolas Goaziou

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAJ+2YJP4eOh9=2moAcMm9ihU_ZC9eWQK+TLCG-qPTrjDZH8tOQ@mail.gmail.com' \
    --to=ligon@are.berkeley.edu \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).