alfresco-ng2-components/lib/config/create-coverage-index.sh
Maurizio Vitale 073311185f [ADF-2788] Fix the process service coverage path and config (#4009)
* Fix the process service coverage path and config

* Create a index report page and run the liteserver
2018-11-27 16:53:32 +00:00

19 lines
493 B
Bash
Executable File

#!/bin/bash
ROOT=./lib/coverage
HTTP="/"
OUTPUT="./lib/coverage/index.html"
RULE=".*\.\(html\)"
echo "<h1>Coverage ADF Reports</h1>" > $OUTPUT
echo "<ul>" >> $OUTPUT
i=0
for filepath in `find "$ROOT" -maxdepth 1 -mindepth 1 -type d| sort`; do
path=`basename "$filepath"`
for i in `find "$filepath" -regex "$RULE" -maxdepth 1 -mindepth 1 -type f| sort`; do
file=`basename "$i"`
echo " <li><a href=\"/$path/$file\">$path</a></li>" >> $OUTPUT
done
done
echo "</ul>" >> $OUTPUT