forked from lumapps/lumX
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.sh
executable file
·57 lines (45 loc) · 868 Bytes
/
build.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
#!/bin/bash
set -x
if [ -z "$release_version" ] && [ -n "$1" ]; then
release_version="$1"
fi
if [ -z "$release_version" ]; then
exit -1
fi
if [[ ! $release_version == v* ]]; then
release_version="v${release_version}"
fi
npm install
if [ $? != 0 ]; then
echo "Error during npm install"
exit -2
fi
gulp clean
rm -rf libs
bower install --allow-root
if [ $? != 0 ]; then
echo "Error during bower install"
exit -3
fi
gulp build
if [ $? != 0 ]; then
echo "Error during gulp build"
exit -4
fi
gulp dist --version "$release_version"
if [ $? != 0 ]; then
echo "Error during gulp dist"
exit -5
fi
if [ -n "$release_version" ]; then
chmod +x release.py
./release.py "$release_version"
if [ $? != 0 ]; then
exit -6
fi
fi
gulp demo
if [ $? != 0 ]; then
echo "Error during gulp demo"
exit -7
fi