summaryrefslogtreecommitdiff
path: root/support/dktools/dktools/htmlbook/old/htmlbook.sh
blob: a88a3365577d56257c7540a3248baf469234c7ae (plain)
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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
#! /bin/sh
EXITCODE=0
rm -fr '/home/joe/work/test-html'
mkdir -p '/home/joe/work/test-html'
if [ -f 'example1.c' ]
then
ln 'example1.c' '/home/joe/work/test-html'
else
echo 'ERROR: File example1.c does not exist'
EXITCODE=1
fi
if [ -f 'favicon.ico' ]
then
ln 'favicon.ico' '/home/joe/work/test-html'
else
echo 'ERROR: File favicon.ico does not exist'
EXITCODE=1
fi
if [ -f 'home.png' ]
then
ln 'home.png' '/home/joe/work/test-html'
else
echo 'ERROR: File home.png does not exist'
EXITCODE=1
fi
if [ -f 'index.png' ]
then
ln 'index.png' '/home/joe/work/test-html'
else
echo 'ERROR: File index.png does not exist'
EXITCODE=1
fi
if [ -f 'mylogo.png' ]
then
ln 'mylogo.png' '/home/joe/work/test-html'
else
echo 'ERROR: File mylogo.png does not exist'
EXITCODE=1
fi
if [ -f 'next.png' ]
then
ln 'next.png' '/home/joe/work/test-html'
else
echo 'ERROR: File next.png does not exist'
EXITCODE=1
fi
if [ -f 'prev.png' ]
then
ln 'prev.png' '/home/joe/work/test-html'
else
echo 'ERROR: File prev.png does not exist'
EXITCODE=1
fi
if [ -f 'style.css' ]
then
ln 'style.css' '/home/joe/work/test-html'
else
echo 'ERROR: File style.css does not exist'
EXITCODE=1
fi
if [ -f 'toc.png' ]
then
ln 'toc.png' '/home/joe/work/test-html'
else
echo 'ERROR: File toc.png does not exist'
EXITCODE=1
fi
if [ -f '/home/joe/work/test-html/index.html' ]
then
rm -fr '/home/joe/work/test-html/index.html'
fi
if [ -f 'index.html' ]
then
echo TIDY index.html
tidy -q -utf8 < 'index.html' > '/home/joe/work/test-html/index.html'
else
echo 'ERROR: File index.html does not exist'
EXITCODE=1
fi
if [ -f '/home/joe/work/test-html/installu.html' ]
then
rm -fr '/home/joe/work/test-html/installu.html'
fi
if [ -f 'installu.html' ]
then
echo TIDY installu.html
tidy -q -utf8 < 'installu.html' > '/home/joe/work/test-html/installu.html'
else
echo 'ERROR: File installu.html does not exist'
EXITCODE=1
fi
if [ -f '/home/joe/work/test-html/instalus.html' ]
then
rm -fr '/home/joe/work/test-html/instalus.html'
fi
if [ -f 'instalus.html' ]
then
echo TIDY instalus.html
tidy -q -utf8 < 'instalus.html' > '/home/joe/work/test-html/instalus.html'
else
echo 'ERROR: File instalus.html does not exist'
EXITCODE=1
fi
if [ -f '/home/joe/work/test-html/instalux.html' ]
then
rm -fr '/home/joe/work/test-html/instalux.html'
fi
if [ -f 'instalux.html' ]
then
echo TIDY instalux.html
tidy -q -utf8 < 'instalux.html' > '/home/joe/work/test-html/instalux.html'
else
echo 'ERROR: File instalux.html does not exist'
EXITCODE=1
fi
if [ -f '/home/joe/work/test-html/installw.html' ]
then
rm -fr '/home/joe/work/test-html/installw.html'
fi
if [ -f 'installw.html' ]
then
echo TIDY installw.html
tidy -q -utf8 < 'installw.html' > '/home/joe/work/test-html/installw.html'
else
echo 'ERROR: File installw.html does not exist'
EXITCODE=1
fi
if [ -f '/home/joe/work/test-html/startu.html' ]
then
rm -fr '/home/joe/work/test-html/startu.html'
fi
if [ -f 'startu.html' ]
then
echo TIDY startu.html
tidy -q -utf8 < 'startu.html' > '/home/joe/work/test-html/startu.html'
else
echo 'ERROR: File startu.html does not exist'
EXITCODE=1
fi
if [ -f '/home/joe/work/test-html/startw.html' ]
then
rm -fr '/home/joe/work/test-html/startw.html'
fi
if [ -f 'startw.html' ]
then
echo TIDY startw.html
tidy -q -utf8 < 'startw.html' > '/home/joe/work/test-html/startw.html'
else
echo 'ERROR: File startw.html does not exist'
EXITCODE=1
fi
find '/home/joe/work/test-html' -type d -exec chmod ugo+rx {} \;
find '/home/joe/work/test-html' -type f -exec chmod ugo+r  {} \;
exit $EXITCODE