forked from mattb112885/clusterDbAnalysis
-
Notifications
You must be signed in to change notification settings - Fork 0
/
dumpDocumentation.sh
executable file
·59 lines (47 loc) · 2.38 KB
/
dumpDocumentation.sh
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
#!/bin/bash
# Note - we only dump documentation for the scripts we expect people to use (i.e. not things in src/internal/)
mkdir "doc" 2> /dev/null
rm doc/help_texts
source SourceMe.sh
echo "o----------------------------------------------------------------------------------------------------------o" >> doc/help_texts
echo "| COMMAND-LINE FUNCTIONS |" >> doc/help_texts
echo "o----------------------------------------------------------------------------------------------------------o" >> doc/help_texts
echo "" >> doc/help_texts
cd src;
for file in *.py; do
echo "*--------------------------------------------------------------------------------------------------------------------------*" >> ../doc/help_texts
echo "" >> ../doc/help_texts
echo "${file}" >> ../doc/help_texts
echo "" >> ../doc/help_texts
${file} -h >> ../doc/help_texts
done
for file in *.sh; do
echo "*--------------------------------------------------------------------------------------------------------------------------*" >> ../doc/help_texts
echo "" >> ../doc/help_texts
echo "${file}" >> ../doc/help_texts
echo "" >> ../doc/help_texts
sh ${file} >> ../doc/help_texts
done
cd utilities;
for file in *.py; do
echo "*--------------------------------------------------------------------------------------------------------------------------*" >> ../../doc/help_texts
echo "" >> ../../doc/help_texts
echo "${file}" >> ../../doc/help_texts
echo "" >> ../../doc/help_texts
${file} -h >> ../../doc/help_texts
done
cd ..;
cd ..;
echo "" >> doc/help_texts
echo "o----------------------------------------------------------------------------------------------------------o" >> doc/help_texts
echo "| CONVENIENCE SCRIPTS |" >> doc/help_texts
echo "o----------------------------------------------------------------------------------------------------------o" >> doc/help_texts
echo "" >> doc/help_texts
cd scripts;
for file in *.sh; do
echo "*--------------------------------------------------------------------------------------------------------------------------*" >> ../doc/help_texts
echo "" >> ../doc/help_texts
echo "${file}" >> ../doc/help_texts
echo "" >> ../doc/help_texts
sh ${file} >> ../doc/help_texts
done