-
Notifications
You must be signed in to change notification settings - Fork 38
/
release.sh
executable file
·70 lines (54 loc) · 1.33 KB
/
release.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
#!/bin/bash
NPM_TAG=$1
if [[ "$1" == "" ]]; then
echo 'usage: release.sh <NPM_TAG>'
exit 1
fi
npm run build
# Build sdk webpack bundle
cd packages/sdk || exit
npm run build-browser
if [ $? -ne 0 ]
then
echo
echo 'SDK build failed, did not publish all packages!'
echo
exit 1
fi
cd ../..
cd packages/utils || exit
npm publish --access public --tag $NPM_TAG
cd ../..
cd packages/test-utils || exit
npm publish --access public --tag $NPM_TAG
cd ../..
cd packages/cdn-location || exit
npm publish --access public --tag $NPM_TAG
cd ../..
cd packages/geoip-location || exit
npm publish --access public --tag $NPM_TAG
cd ../..
cd packages/proto-rpc || exit
npm publish --access public --tag $NPM_TAG
cd ../..
cd packages/autocertifier-client || exit
npm publish --access public --tag $NPM_TAG
cd ../..
cd packages/dht || exit
npm publish --access public --tag $NPM_TAG
cd ../..
cd packages/autocertifier-server || exit
npm publish --access public --tag $NPM_TAG
cd ../..
cd packages/trackerless-network || exit
npm publish --access public --tag $NPM_TAG
cd ../..
cd packages/sdk/dist || exit # Notice: dist folder
npm publish --access public --tag $NPM_TAG
cd ../../..
cd packages/node || exit
npm publish --tag $NPM_TAG --access public
cd ../..
cd packages/cli-tools || exit
npm publish --tag $NPM_TAG --access public
cd ../..