Generate index page for robot html files
[docs.git] / docs / build-integration-robot-libdoc.sh
index 414a81217aca3c2ae02dc329a7c5308ed0acbc7e..04cf3c787d881ba17df419cfd1203149ac8de224 100755 (executable)
@@ -7,5 +7,11 @@ mkdir -p $ROBOT_DIR $TMP_ROBOT_DIR
 cd submodules/integration/test/csit/libraries
 for f in *.robot; do python -m robot.libdoc $f $TMP_ROBOT_DIR/$f.html; done
 for f in *.py; do python -m robot.libdoc $f $TMP_ROBOT_DIR/$f.html > /dev/null 2>&1; done
+
 cd $TMP_ROBOT_DIR/
-for f in *.html; do sed 's/black/orange/; s/white/black/; s/^<body>/<body><img src="..\/..\/odl.png">/' $f > $ROBOT_DIR/$f; done
+echo "<html><body><ul>" > $ROBOT_DIR/index.html
+for f in *.html; do
+    sed 's/black/orange/; s/white/black/; s/^<body>/<body><img src="..\/..\/odl.png">/' $f > $ROBOT_DIR/$f
+    echo "<li><a href=\"$f\">$f</a></li>" >> $ROBOT_DIR/index.html
+done
+echo "</ul></body></html>" >> $ROBOT_DIR/index.html