-
Notifications
You must be signed in to change notification settings - Fork 41
/
Copy pathrelease.sh
executable file
·75 lines (57 loc) · 1.46 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
71
72
73
74
75
#!/bin/bash
NPM_TAG=$1
if [[ "$1" == "" ]]; then
echo 'usage: release.sh <NPM_TAG>'
exit 1
fi
# check that there was some tag value selected in the manual workflow UI (see publish-npm.yml)
if [[ "$1" == "SELECT" ]]; then
echo 'invalid value for "tag"'
exit 1
fi
npm run build
# Build sdk webpack bundle
npm run build-browser -w packages/sdk
if [ $? -ne 0 ]
then
echo
echo 'SDK build failed, did not publish all packages!'
echo
exit 1
fi
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 || exit
npm publish --access public --tag $NPM_TAG
cd ../..
cd packages/node || exit
npm publish --access public --tag $NPM_TAG
cd ../..
cd packages/cli-tools || exit
npm publish --access public --tag $NPM_TAG
cd ../..