We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b683f52 commit 3a10a23Copy full SHA for 3a10a23
scripts/publish.sh
@@ -3,6 +3,18 @@
3
VERSION=$(echo $1 | sed 's/v//')
4
shift
5
6
+function retry {
7
+ for i in {0..10}; do
8
+ $@
9
+ if [ $? -eq 0 ]; then
10
+ exit 0
11
+ fi
12
+ sleep 3
13
+ done
14
+ exit 1
15
+}
16
+
17
18
declare -a PROJECTS=(
19
gluon_codegen
20
gluon_base
@@ -21,9 +33,7 @@ for PROJECT in "${PROJECTS[@]}"
21
33
do
22
34
PROJECT_PATH=$(echo "$PROJECT" | sed 's/gluon_//' | sed 's/gluon/./')
23
35
24
- if ! (cd "${PROJECT_PATH}" && cargo publish "$@"); then
36
+ if ! (cd "${PROJECT_PATH}" && retry cargo publish "$@"); then
25
37
exit 1
26
38
fi
27
- echo "Waiting for ${PROJECT} to publish"
28
- sleep 25
29
39
done
0 commit comments