2016-03-19 13:45:40 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
if ! [ -d "./.git" ]
|
|
|
|
then
|
|
|
|
echo "Should be executed from the repo root."
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
|
|
|
#rm #+HTML_HEAD_EXTRA: ... readtheorg.css" /> in the doc.
|
2016-03-31 02:59:55 +00:00
|
|
|
find ./doc -name "*.org" -type f -exec gsed -i '/#+HTML_HEAD_EXTRA.*readtheorg.css.*/d' {} \;
|
2016-03-19 13:45:40 +00:00
|
|
|
|
|
|
|
#rm #+HTML_HEAD_EXTRA: ... readtheorg.css" /> in the layers.
|
2016-03-31 02:59:55 +00:00
|
|
|
find ./layers -name "*.org" -type f -exec gsed -i '/#+HTML_HEAD_EXTRA.*readtheorg.css.*/d' {} \;
|
2016-03-19 13:45:40 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#replace :TOC_4_org: with :TOC_4_gh: in the doc.
|
2016-03-31 02:59:55 +00:00
|
|
|
find ./doc -name "*.org" -type f -exec gsed -i 's/:TOC_4_org:/:TOC_4_gh:/' {} \;
|
2016-03-19 13:45:40 +00:00
|
|
|
|
|
|
|
#replace :TOC_4_org: with :TOC_4_gh: in the layers.
|
2016-03-31 02:59:55 +00:00
|
|
|
find ./layers -name "*.org" -type f -exec gsed -i 's/:TOC_4_org:/:TOC_4_gh:/' {} \;
|
2016-03-19 13:45:40 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#apply toc-org to doc.
|
2016-04-01 03:58:11 +00:00
|
|
|
find ./doc -name "*.org" -type f -exec emacs -batch -l ./core/tools/doc-fmt/toc-org-apply.el '{}' -f toc-apply \;
|
2016-03-19 13:45:40 +00:00
|
|
|
|
|
|
|
#apply toc-org to layers.
|
2016-04-01 03:58:11 +00:00
|
|
|
find ./layers -name "*.org" -type f -exec emacs -batch -l ./core/tools/doc-fmt/toc-org-apply.el '{}' -f toc-apply \;
|