-
Notifications
You must be signed in to change notification settings - Fork 146
/
travis.sh
76 lines (46 loc) · 1.1 KB
/
travis.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
#!/bin/sh
FILE_NAME="noahv"
CUR_DIR=$(cd `dirname $0`; pwd)
# prepare
if [ -d $CUR_DIR/template/common/noahv ]; then
rm -rf $CUR_DIR/template/common/noahv
fi
cd $CUR_DIR/template/common
echo "install node_module"
npm install
# build
echo "start build common project"
node scripts/build.js
if [ $? -ne 0 ]; then
echo "common project build failed!"
exit 1;
fi
echo "common project build success"
# prepare
if [ -d $CUR_DIR/template/dashboard/noahv ]; then
rm -rf $CUR_DIR/template/dashboard/noahv
fi
cd $CUR_DIR/template/dashboard
echo "install node_module"
npm install
# build
echo "start build dashboard project"
node scripts/build.js
if [ $? -ne 0 ]; then
echo "dashboard project build failed!"
exit 1;
fi
echo "dashboard project build success"
# test:coverage
cd $CUR_DIR/components/common
echo "install node_module for common components"
npm install
# build
npm run test:coverage
echo "common components tested"
cd $CUR_DIR/components/visual
echo "install node_module for visual components"
npm install
# build
npm run test:coverage
echo "visual components tested"