view tangle.sh @ 6:5370428e673e

experimenting with a perlscript for weaving
author Robert McIntyre <rlm@mit.edu>
date Mon, 24 Oct 2011 09:29:17 -0700
parents de36470a2f70
children 73beed20f7de
line wrap: on
line source
1 #!/bin/sh
2 # assumes that there is a ./org directory, and tangles
3 # each org file in it.
5 DIR=`pwd`
6 FILES=""
8 for i in $(find $DIR/org -name "*.org"); do
9 FILES="$FILES \"$i\""
10 done
13 emacs --batch \
14 -l /home/r/config/emacs/clojure-init.el \
15 -l /home/r/config/emacs/org-init.el \
16 --eval "(progn
17 (mapc (lambda (file)
18 (find-file (expand-file-name file \"$DIR\"))
19 (org-babel-tangle)
20 (kill-buffer)) '($FILES)))" 2>&1 | pcregrep '(Wrote)|(tangled)'