Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Make sure to exit publish script with correct code (#10310)
- Loading branch information
Showing
with
10 additions
and
0 deletions.
-
+10
−0
publish-release.sh
|
|
@@ -18,13 +18,23 @@ if [[ $(git describe --exact-match 2> /dev/null || :) =~ -canary ]]; |
|
|
then |
|
|
echo "Publishing canary" |
|
|
yarn run lerna publish from-git --npm-tag canary --yes |
|
|
|
|
|
# Make sure to exit script with code 1 if publish failed |
|
|
if [[ ! $? -eq 0 ]];then |
|
|
exit 1; |
|
|
fi |
|
|
else |
|
|
echo "Did not publish canary" |
|
|
fi |
|
|
|
|
|
if [[ ! $(git describe --exact-match 2> /dev/null || :) =~ -canary ]];then |
|
|
echo "Publishing stable" |
|
|
yarn run lerna publish from-git --yes |
|
|
|
|
|
# Make sure to exit script with code 1 if publish failed |
|
|
if [[ ! $? -eq 0 ]];then |
|
|
exit 1; |
|
|
fi |
|
|
else |
|
|
echo "Did not publish stable" |
|
|
fi |