-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgendoc
executable file
·42 lines (34 loc) · 931 Bytes
/
gendoc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
#!/bin/bash
#+
# Generate the html documentation for the test library.
#-
source scripts/mistify-test-functions.sh
testlib=testlib
testlibdir=`pwd`/$testlib
outdir=`pwd`/doc
usage () {
message There are no parameters for this script.
cat << EOF
Usage: $0
Use this script to generate html documentation. The generated documentation
is placed in the directory named "$outdir".
EOF
}
genresourcedoc () {
mkdir -p $outdir/$1
for f in $( ls $testlib/$1/*.robot ); do
message Generating html doc for: $f
python -m robot.libdoc -f html -F robot $f $outdir/$1/$(basename $f).html
done
}
if [ -n "$1" ]; then
usage
exit 1
fi
message Generating test library html documentation.
rm -rf $outdir
mkdir -p $outdir && python -m robot.testdoc $testlibdir $outdir/$testlib.html
for d in resources distros repos testbeds; do
message Generating html doc for directory: $d
genresourcedoc $d
done