-
Notifications
You must be signed in to change notification settings - Fork 20
/
git.sh
executable file
·34 lines (24 loc) · 1.04 KB
/
git.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
#!/bin/bash
echo "LOG: `date '+%Y-%m-%d %H:%M:%S'` - Starting Dashboard generation"
echo "LOG: `date '+%Y-%m-%d %H:%M:%S'` - Removing 'out' directory and creating a new one"
rm -rf out
mkdir out
echo "LOG: `date '+%Y-%m-%d %H:%M:%S'` - Fetching data"
./fetch_data.sh &> fetch_data.log || exit 1
echo "LOG: `date '+%Y-%m-%d %H:%M:%S'` - Running plots.py"
python plots.py || exit 1
echo "LOG: `date '+%Y-%m-%d %H:%M:%S'` - Running make_csv.py"
python make_csv.py || exit 1
echo "LOG: `date '+%Y-%m-%d %H:%M:%S'` - Running speakers kit.py"
python speakers_kit.py || exit 1
echo "LOG: `date '+%Y-%m-%d %H:%M:%S'` - Running make_html.py"
python make_html.py $1 $2|| exit 1
echo "LOG: `date '+%Y-%m-%d %H:%M:%S'` - Copying static elements"
cp static/img/favicon.png out/
cp static/img/tablesorter-icons.gif out/
echo "LOG: `date '+%Y-%m-%d %H:%M:%S'` - Make a backup of the old web directory and make new content live"
rsync -a --delete web web.bk
mv web web.1
mv out web
rm -rf web.1
echo "LOG: `date '+%Y-%m-%d %H:%M:%S'` - Dashboard generation complete"