Mercurial > org-tools
annotate weave.sh @ 7:ce96610fe058
perl script is amazing
author | Robert McIntyre <rlm@mit.edu> |
---|---|
date | Mon, 24 Oct 2011 09:41:38 -0700 |
parents | 5370428e673e |
children | 73beed20f7de |
rev | line source |
---|---|
rlm@1 | 1 #!/bin/sh |
rlm@1 | 2 |
rlm@1 | 3 # assumes ./org directory with org files to publish to |
rlm@1 | 4 # ./html |
rlm@1 | 5 |
rlm@6 | 6 target=$(readlink -f $1) |
rlm@1 | 7 |
rlm@7 | 8 org=`dirname $target` |
rlm@7 | 9 |
rlm@7 | 10 dir=`dirname $org` |
rlm@1 | 11 |
rlm@6 | 12 emacsclient \ |
rlm@1 | 13 --eval " |
rlm@1 | 14 (progn |
rlm@1 | 15 (setq org-publish-project-alist |
rlm@1 | 16 '( |
rlm@1 | 17 (\"project\" |
rlm@1 | 18 :base-directory \"$dir/org\" |
rlm@1 | 19 :base-extension \"org\" |
rlm@1 | 20 :publishing-directory \"$dir/html\" |
rlm@1 | 21 :recursive t |
rlm@1 | 22 :publishing-function org-publish-org-to-html |
rlm@1 | 23 :auto-preamble t) |
rlm@1 | 24 )) |
rlm@1 | 25 |
rlm@6 | 26 (org-publish-file \"$target\" '(\"project\" |
rlm@6 | 27 :base-directory \"$dir/org\" |
rlm@6 | 28 :base-extension \"org\" |
rlm@6 | 29 :publishing-directory \"$dir/html\" |
rlm@6 | 30 :recursive t |
rlm@6 | 31 :publishing-function org-publish-org-to-html |
rlm@6 | 32 :auto-preamble t) |
rlm@6 | 33 ))" \ |
rlm@6 | 34 \ |
rlm@6 | 35 2>&1 #| pcregrep 'Wrote' |
rlm@1 | 36 |
rlm@1 | 37 |
rlm@1 | 38 |
rlm@5 | 39 |
rlm@6 | 40 |
rlm@6 | 41 |
rlm@6 | 42 |