-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathupdate.sh
executable file
·49 lines (42 loc) · 1.19 KB
/
update.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
cp ../secrets.php ../secrets_save.php
cp ../secrets_public.php ../secrets.php
cp -a ../tui/room php
cp -a ../tui/small php
mv php/room/system-calendar-demo.php php/room/system-calendar.php
rm php/room/test*.*
rm php/room/daydream.php
cp -a ../tui/css html
cp -a ../tui/js/ html
cp -a ../tui/fonts/ html
cp -a ../tui/images/ html
# room
mkdir download
cd download
for p in ../php/room/*.php; do r=`echo "$p"|sed -s "s#../php#http://wopr/tui#"`; wget -q $r; done;
rm ui.php
for p in *.php; do mv "$p" "`echo \"$p\"|sed -s 's#\.php$#.html#'`"; done;
cd ..
rm -r html/room/*
mv download/* html/room/
rm -r download
# small
mkdir download
cd download
for p in ../php/small/*.php; do r=`echo "$p"|sed -s "s#../php#http://wopr/tui#"`; wget -q $r; done;
rm ui.php
for p in *.php; do mv "$p" "`echo \"$p\"|sed -s 's#\.php$#.html#'`"; done;
cd ..
rm -r html/small/*
mv download/* html/small/
rm -r download
for h in html/room/*.html
do b=`basename "$h"`
p=`echo "$b"|sed -s 's#\.html$#.png#'`
if [ ! -e "screenshots/$p" ]
then echo "$p is missing"
fi
done
for p in screenshots/*.png
do convert -resize 400x400 "$p" "screenshots/small/`basename $p`"
done
mv ../secrets_save.php ../secrets.php