This repository has been archived by the owner on Feb 26, 2018. It is now read-only.
/
package.sh
executable file
·94 lines (68 loc) · 1.97 KB
/
package.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
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
#!/bin/bash
echo ""
echo -e "\E[94mAXIHOME\033[0m"
echo -e "\E[94m------------------------------------\033[0m"
echo ""
DEPLOYPATH=deploy/axihome
rm -rf DEPLOYPATH
mkdir -p $DEPLOYPATH 2>/dev/null
echo ""
echo -e "\E[94mGenerating assets\033[0m"
echo ""
mkdir $DEPLOYPATH/assets 2>/dev/null
cd src/github.com/think-free/axihome/
zip -r axihome.assets assets/
mv axihome.assets ../../../../$DEPLOYPATH/assets
cd ../../../../
echo ""
echo -e "\E[94mDeploying binaries\033[0m"
echo ""
mkdir -p $DEPLOYPATH/bin 2>/dev/null
cp bin-arm/axihome/* $DEPLOYPATH/bin/
echo ""
echo -e "\E[94mDeploying service\033[0m"
echo ""
cp src/github.com/think-free/axihome/axihome.service $DEPLOYPATH/
echo ""
echo -e "\E[94mDeploying importer\033[0m"
echo ""
cp src/github.com/think-free/axihome/importer.sh $DEPLOYPATH/
echo ""
echo -e "\E[94mDeploying install script\033[0m"
echo ""
cp src/github.com/think-free/axihome/install.sh $DEPLOYPATH/
echo ""
echo -e "\E[94mGenerate .run\033[0m"
echo ""
cd deploy
chmod +x axihome/install.sh
makeself axihome axihome.`date +%Y.%m.%d`.run "Axihome automation" ./install.sh
cd ..
echo ""
echo -e "\E[94mDone\033[0m"
echo ""
echo ""
echo -e "\E[94mVOICENOTIFIER\033[0m"
echo -e "\E[94m------------------------------------\033[0m"
echo ""
DEPLOYPATH=deploy/voicenotifier
rm -rf DEPLOYPATH
mkdir -p $DEPLOYPATH 2>/dev/null
echo ""
echo -e "\E[94mDeploying binaries\033[0m"
echo ""
mkdir -p $DEPLOYPATH/bin 2>/dev/null
cp bin-arm/voicenotifier/* $DEPLOYPATH/
echo ""
echo -e "\E[94mDeploying application\033[0m"
echo ""
cp src/github.com/think-free/axihome/apps/voicenotifier/svox-pico.tar.gz $DEPLOYPATH/
cp src/github.com/think-free/axihome/apps/voicenotifier/voicenotifier.service $DEPLOYPATH/
cp src/github.com/think-free/axihome/apps/voicenotifier/install.sh $DEPLOYPATH/
echo ""
echo -e "\E[94mGenerate .run\033[0m"
echo ""
cd deploy
chmod +x voicenotifier/install.sh
makeself voicenotifier voicenotifier.`date +%Y.%m.%d`.run "Voice Notifier" ./install.sh
cd ..