From d1e3905f422f522e77d1b12ebb1466828bf2b739 Mon Sep 17 00:00:00 2001 From: cutealien Date: Thu, 18 Mar 2021 21:37:48 +0000 Subject: [PATCH] Update scripts to build tutorials. Adding some more sed magic and error checking. git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6203 dfc29bdd-3216-0410-991c-e03cc46cb475 --- scripts/doc/irrlicht/maketut.sed | 5 ++++- scripts/doc/irrlicht/maketutorial.sh | 7 ++++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/scripts/doc/irrlicht/maketut.sed b/scripts/doc/irrlicht/maketut.sed index d86a7955..5d824c14 100644 --- a/scripts/doc/irrlicht/maketut.sed +++ b/scripts/doc/irrlicht/maketut.sed @@ -1,4 +1,7 @@ # run on single_tut.txt which is created in maketutorial.sh (or .bat) # replace image links as we don't copy the images into example folders but keep them below media folder -s/img src="/img src="..\/..\/media\// +# most images should be in media +s/img src="/img src="..\/..\/media\//g +# ???shots.jpg files are in media/example_screenshots another subfolder (earlier replacement already moved them to ../../media/) +s/img src="..\/..\/media\/\([0-9]\{3\}shot\)/img src="..\/..\/media\/example_screenshots\/\1/ diff --git a/scripts/doc/irrlicht/maketutorial.sh b/scripts/doc/irrlicht/maketutorial.sh index 2d83f40b..1038e5d9 100755 --- a/scripts/doc/irrlicht/maketutorial.sh +++ b/scripts/doc/irrlicht/maketutorial.sh @@ -1,9 +1,14 @@ # Create the tutorial.html files in each example folder # for every folder below examples -for i in ../../../examples/[012]*; do +for i in ../../../examples/[0123]*; do +#for i in ../../../examples/01.*; do # if you want to run/update a single example use this loop echo NOW doing $i + if ! [ -f "$i/main.cpp" ]; then + continue + fi + # uses the main.cpp files to create some file to use as doxygen input sed -f tutorials.sed $i/main.cpp >single_tut.txt # echo tutorials.sed has run